bullseye-arrowInstallation

This section will guide you through the installation of FedPruning.

Step 0. Install Anaconda

First, download and install Anaconda by following the instructions at Anaconda’s official websitearrow-up-right, based on your machine’s operating system.

Step 1. Clone the Repository

Clone the FedPruning repository by running the following command:

git clone git@github.com:FedPruning/FedPruning.git

Step 2. Quick Installation of Prerequisites

Set up the necessary environment and dependencies with the following commands:

# Create a new conda environment for FedPruning
conda create -n fedprune python=3.10

# Activate the environment
conda activate fedprune

# Install PyTorch and CUDA toolkits,
# assuming the CUDA version on the computer is 11.8.
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118

# Install MPI for Python
conda install -c anaconda mpi4py

# Install additional dependencies from the requirements file
pip install -r requirements.txt

Last updated