Skip to content
Snippets Groups Projects
Commit 4ca97ba2 authored by huongdm1896's avatar huongdm1896
Browse files

readme update

parent 44884f33
Branches
Tags
No related merge requests found
...@@ -198,8 +198,6 @@ cat config_instances_CPU.json ...@@ -198,8 +198,6 @@ cat config_instances_CPU.json
- instance "`1`": fedAvg, cifar10, dvfs with min and max CPU freq, 1 round. - 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. - instance "`2`": fedAvg2Clients, cifar10, dvfs with min and max CPU freq, 1 round.
Total test time is about 5 minutes.
### Step 3. Collect IP ### Step 3. Collect IP
Run the following command to collect/generate a node list: 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: ...@@ -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 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 ### Step 5. Output
The logs and energy monitoring data will be saved in the directory specified in the JSON configuration. 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 ```plaintext
Log/Flower_CampaignTest Log/Flower_SingleTest
├── Flower_instance_Flower_instance_fedAvg_cifar10 ├── Flower_instance_Flower_instance_fedAvg_cifar10
│ ├── Expetator │ ├── Expetator
| | ├── config_instance_1.json | | ├── config_instance_1.json
...@@ -245,10 +245,15 @@ Log/Flower_CampaignTest ...@@ -245,10 +245,15 @@ Log/Flower_CampaignTest
│ ├── Flwr_<timestamp> │ ├── Flwr_<timestamp>
│ │ ├── Client_<ip> │ │ ├── Client_<ip>
│ │ ├── Server_<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 ### Step 6. Clean Up
After the experiment, exit the host and kill job if needed: After the experiment, exit the host and kill job if needed:
......
...@@ -6,13 +6,13 @@ ...@@ -6,13 +6,13 @@
"dvfs_cpu": { "dvfs_cpu": {
"dummy": false, "dummy": false,
"baseline": false, "baseline": false,
"frequencies": null "frequencies": [1200000,1500000,1800000,2100000]
}, },
"server": { "server": {
"command": "python3", "command": "python3",
"args": [ "args": [
"./Flower_v1/server_1.py", "./Flower_v1/server_1.py",
"-r 1", "-r 15",
"-s fedAvg" "-s fedAvg"
], ],
"ip": "172.16.66.76", "ip": "172.16.66.76",
...@@ -56,128 +56,18 @@ ...@@ -56,128 +56,18 @@
] ]
}, },
"2": { "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", "instance": "fedAvg2Clients_cifar10",
"output_dir": "./Log", "output_dir": "./Log",
"dvfs_cpu": { "dvfs_cpu": {
"dummy": true, "dummy": false,
"baseline": false, "baseline": false,
"frequencies": null "frequencies": [1200000,1500000,1800000,2100000]
}, },
"server": { "server": {
"command": "python3", "command": "python3",
"args": [ "args": [
"./Flower_v1/server_1.py", "./Flower_v1/server_1.py",
"-r 1", "-r 15",
"-s fedAvg2Clients" "-s fedAvg2Clients"
], ],
"ip": "172.16.66.76", "ip": "172.16.66.76",
...@@ -219,116 +109,6 @@ ...@@ -219,116 +109,6 @@
"ip": "172.16.66.79" "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
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment