gnss_federated_learning / Scripts /env_federated_run.sh
FelixOtt's picture
Upload folder using huggingface_hub
29d330e verified
Raw History Blame Contribute Delete
916 Bytes
#!/bin/bash
#SBATCH --nodelist=hpc-gpu-01
#SBATCH --partition=gpu-short # Specify the CPU partition
#SBATCH --nodes=1
#SBATCH --gres=gpu:tesla:1
#SBATCH --mem-per-cpu=8000
#SBATCH --job-name=6Prox# Specify the job name
#SBATCH --output=../logs/6Prox_output.log
#SBATCH --error=../logs/6Prox_error.log
cd ../Flower_federated
# Request specific CPU node
echo "run started $2 $3"
if [ "$1" == 0 ]; then
srun -p gpu -n 1 --gres=gpu:tesla:1 --mem-per-gpu=6000 ~/miniconda3/envs/final_test_env/bin/python server.py $2 $3 $4 $5 $6 $7 $8 $9
# Run clients on the specified CPU node
elif [ "$1" == 1 ]; then
srun -p gpu -n 1 --gres=gpu:tesla:1 --mem-per-gpu=6000 ~/miniconda3/envs/final_test_env/bin/python client_1.py $2 $3 $4 $5 $6 $7 $8 $9
elif [ "$1" == 2 ]; then
srun -p gpu -n 1 --gres=gpu:tesla:1 --mem-per-gpu=6000 ~/miniconda3/envs/final_test_env/bin/python client_2.py $2 $3 $4 $5 $6 $7 $8 $9
fi