From a9d65e7acc48a45793a4dc75d5b15fca8a209062 Mon Sep 17 00:00:00 2001 From: alexliang Date: Tue, 4 Oct 2022 18:18:09 +0800 Subject: [PATCH] update samples. --- devops/scripts/build-docs.sh | 1 - .../custom_data_and_model/config/fedml_config.yaml | 3 --- .../custom_data_and_model/torch_client.py | 3 --- .../custom_data_and_model/torch_server.py | 3 --- 4 files changed, 10 deletions(-) diff --git a/devops/scripts/build-docs.sh b/devops/scripts/build-docs.sh index 3f1a8f5502..fafc3df6e5 100755 --- a/devops/scripts/build-docs.sh +++ b/devops/scripts/build-docs.sh @@ -1,6 +1,5 @@ #!/usr/bin/env bash -WORKSPACE=./ wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh bash miniconda.sh -b -p $WORKSPACE/miniconda hash -r diff --git a/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/config/fedml_config.yaml b/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/config/fedml_config.yaml index 2106964248..36c37b9477 100644 --- a/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/config/fedml_config.yaml +++ b/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/config/fedml_config.yaml @@ -40,15 +40,12 @@ device_args: gpu_mapping_key: mapping_default comm_args: - #backend: "MQTT_IPFS" backend: "MQTT_S3" mqtt_config_path: config/mqtt_config.yaml s3_config_path: config/s3_config.yaml # If you want to use your customized MQTT or s3 server as training backends, you should uncomment and set the following lines. #customized_training_mqtt_config: {'BROKER_HOST': 'your mqtt server address or domain name', 'MQTT_PWD': 'your mqtt password', 'BROKER_PORT': 1883, 'MQTT_KEEPALIVE': 180, 'MQTT_USER': 'your mqtt user'} #customized_training_s3_config: {'CN_S3_SAK': 'your s3 aws_secret_access_key', 'CN_REGION_NAME': 'your s3 region name', 'CN_S3_AKI': 'your s3 aws_access_key_id', 'BUCKET_NAME': 'your s3 bucket name'} - #customized_training_ipfs_config: {'token': 'your ipfs token at web3.storage', 'upload_uri': 'https://api.web3.storage/upload', 'download_uri': 'ipfs.w3s.link', } - #customized_training_ipfs_config: {'token': 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJkaWQ6ZXRocjoweERiNzY5OTdGRUFBRjg3QjY0RDc3MWZBYjg2RUExMTg2ODRBOEI0MTUiLCJpc3MiOiJ3ZWIzLXN0b3JhZ2UiLCJpYXQiOjE2NjM0OTkwNzQ3MzQsIm5hbWUiOiJmZWRtbC13ZWIzIn0.VV8WHJaqe8cbShek8warIGFbS55KOUfpgtLMRevPIIY', 'upload_uri': 'https://api.web3.storage/upload', 'download_uri': 'ipfs.w3s.link', } tracking_args: # the default log path is at ~/fedml-client/fedml/logs/ and ~/fedml-server/fedml/logs/ diff --git a/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_client.py b/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_client.py index 2cd9a66834..00c8253b86 100644 --- a/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_client.py +++ b/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_client.py @@ -4,7 +4,6 @@ from fedml import FedMLRunner import fedml from fedml.data.MNIST.data_loader import download_mnist, load_partition_data_mnist -from fedml.core.alg_frame.context import Context def load_data(args): @@ -59,8 +58,6 @@ def forward(self, x): if __name__ == "__main__": - Context().add("ipfs_secret_key", "12345678123456781234567812345678") - # init FedML framework args = fedml.init() diff --git a/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_server.py b/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_server.py index 5970e5f24f..14eb9b96b7 100644 --- a/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_server.py +++ b/python/examples/cross_silo/mqtt_s3_fedavg_mnist_lr_example/custom_data_and_model/torch_server.py @@ -3,7 +3,6 @@ import fedml from fedml import FedMLRunner from fedml.data.MNIST.data_loader import download_mnist, load_partition_data_mnist -from fedml.core.alg_frame.context import Context def load_data(args): @@ -58,8 +57,6 @@ def forward(self, x): if __name__ == "__main__": - Context().add("ipfs_secret_key", "12345678123456781234567812345678") - # init FedML framework args = fedml.init()