Magneton is an energy profiler for machine learning systems. Currently, it can provide energy consumption of each CUDA kernel in a Python application.
You need to install uv, clang-18, and boost-1.74 to build the project. On Ubuntu, you can install them by:
# Install python and uv
sudo apt install -y python3 python3-pip clang g++ libboost-all-dev
pip3 install uvIf you are using Ubuntu 22.04, you may need to manually install clang-18 by:
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
sudo add-apt-repository "deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-18 main"
sudo apt update
sudo apt install -y clang-18Clone the repository:
git clone https://github.com/uw-syfi/Magneton.git
cd MagnetonInstall the project:
uv pip install -e .If clang-18 is not set as the default compiler, you should set the environment variable CC and CXX to clang-18 and clang++-18 respectively when installing the project.