diff --git a/README.md b/README.md index 02e2adce928d6581793694f2abec9905ffa607eb..2c46cecfc818e3490a03da3f8c9870a8a25a2dbf 100644 --- a/README.md +++ b/README.md @@ -198,8 +198,6 @@ cat config_instances_CPU.json - instance "`1`": fedAvg, cifar10, dvfs with min and max CPU freq, 1 round. - instance "`2`": fedAvg2Clients, cifar10, dvfs with min and max CPU freq, 1 round. -Total test time is about 5 minutes. - ### Step 3. Collect IP Run the following command to collect/generate a node list: @@ -224,14 +222,16 @@ Run a campaign with all instances (`1` and `2`), and 2 repetitions: python3 measure_campaign.py -x CampaignTest -c config_instances_CPU.json -r 2 ``` +**Note**: Running single instance takes about 6 mins (1 round (80s) * 2 repetitions * 2 freqs = 320s). Running a campaign (2 instances) takes about 12 mins. + ### Step 5. Output The logs and energy monitoring data will be saved in the directory specified in the JSON configuration. -Output dir structure: +Output dir structure for demo single instance: Log/Flower_SingleTest/Flower_instance_Flower_instance_fedAvg_cifar10 ```plaintext -Log/Flower_CampaignTest +Log/Flower_SingleTest ├── Flower_instance_Flower_instance_fedAvg_cifar10 │ ├── Expetator | | ├── config_instance_1.json @@ -245,10 +245,15 @@ Log/Flower_CampaignTest │ ├── Flwr_<timestamp> │ │ ├── Client_<ip> │ │ ├── Server_<ip> -│── Flower_instance_Flower_instance_fedAvg2Clients_cifar10 ... ``` +Output dir structure for demo campaign, includes 2 folders for 2 instances: +```plaintext +Log/Flower_CampaignTest +├── Flower_instance_Flower_instance_fedAvg_cifar10 +├── Flower_instance_Flower_instance_fedAvg2Clients_cifar10 +... ### Step 6. Clean Up After the experiment, exit the host and kill job if needed: diff --git a/Run/config_instances.json b/Run/config_instances.json index 924bd9b64111593e4bbb84de67acfc10532d731c..8617efb40033c33a1a4204eea49959decce1b721 100644 --- a/Run/config_instances.json +++ b/Run/config_instances.json @@ -6,13 +6,13 @@ "dvfs_cpu": { "dummy": false, "baseline": false, - "frequencies": null + "frequencies": [1200000,1500000,1800000,2100000] }, "server": { "command": "python3", "args": [ "./Flower_v1/server_1.py", - "-r 1", + "-r 15", "-s fedAvg" ], "ip": "172.16.66.76", @@ -56,128 +56,18 @@ ] }, "2": { - "instance": "fedAvg_cifar100", - "output_dir": "./Log", - "dvfs_cpu": { - "dummy": true, - "baseline": false, - "frequencies": null - }, - "server": { - "command": "python3", - "args": [ - "./Flower_v1/server_1.py", - "-r 1", - "-s fedAvg" - ], - "ip": "172.16.66.76", - "modules": ["logger"], - "port": 8080 - }, - "clients": [ - { - "name": "client1", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "cifar100", - "0", - "3" - ], - "ip": "172.16.66.77" - }, - { - "name": "client2", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "cifar100", - "1", - "3" - ], - "ip": "172.16.66.78" - }, - { - "name": "client3", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "cifar100", - "2", - "3" - ], - "ip": "172.16.66.79" - } - ] - }, - "3": { - "instance": "fedAvg_mnist", - "output_dir": "./Log", - "dvfs_cpu": { - "dummy": true, - "baseline": false, - "frequencies": null - }, - "server": { - "command": "python3", - "args": [ - "./Flower_v1/server_1.py", - "-r 1", - "-s fedAvg" - ], - "ip": "172.16.66.76", - "modules": ["logger"], - "port": 8080 - }, - "clients": [ - { - "name": "client1", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "mnist", - "0", - "3" - ], - "ip": "172.16.66.77" - }, - { - "name": "client2", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "mnist", - "1", - "3" - ], - "ip": "172.16.66.78" - }, - { - "name": "client3", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "mnist", - "2", - "3" - ], - "ip": "172.16.66.79" - } - ] - }, - "4": { "instance": "fedAvg2Clients_cifar10", "output_dir": "./Log", "dvfs_cpu": { - "dummy": true, + "dummy": false, "baseline": false, - "frequencies": null + "frequencies": [1200000,1500000,1800000,2100000] }, "server": { "command": "python3", "args": [ "./Flower_v1/server_1.py", - "-r 1", + "-r 15", "-s fedAvg2Clients" ], "ip": "172.16.66.76", @@ -219,116 +109,6 @@ "ip": "172.16.66.79" } ] - }, - "5": { - "instance": "fedAvg2Clients_cifar100", - "output_dir": "./Log", - "dvfs_cpu": { - "dummy": true, - "baseline": false, - "frequencies": null - }, - "server": { - "command": "python3", - "args": [ - "./Flower_v1/server_1.py", - "-r 1", - "-s fedAvg2Clients" - ], - "ip": "172.16.66.76", - "modules": ["logger"], - "port": 8080 - }, - "clients": [ - { - "name": "client1", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "cifar100", - "0", - "3" - ], - "ip": "172.16.66.77" - }, - { - "name": "client2", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "cifar100", - "1", - "3" - ], - "ip": "172.16.66.78" - }, - { - "name": "client3", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "cifar100", - "2", - "3" - ], - "ip": "172.16.66.79" - } - ] - }, - "6": { - "instance": "fedAvg2Clients_mnist", - "output_dir": "./Log", - "dvfs_cpu": { - "dummy": true, - "baseline": false, - "frequencies": null - }, - "server": { - "command": "python3", - "args": [ - "./Flower_v1/server_1.py", - "-r 1", - "-s fedAvg2Clients" - ], - "ip": "172.16.66.76", - "modules": ["logger"], - "port": 8080 - }, - "clients": [ - { - "name": "client1", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "mnist", - "0", - "3" - ], - "ip": "172.16.66.77" - }, - { - "name": "client2", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "mnist", - "1", - "3" - ], - "ip": "172.16.66.78" - }, - { - "name": "client3", - "command": "python3", - "args": [ - "./Flower_v1/client_1.py", - "mnist", - "2", - "3" - ], - "ip": "172.16.66.79" - } - ] } } } \ No newline at end of file