diff --git a/examples/async_fl/async_aggregator.py b/examples/async_fl/async_aggregator.py index a30c39ed..f0dcc454 100644 --- a/examples/async_fl/async_aggregator.py +++ b/examples/async_fl/async_aggregator.py @@ -5,6 +5,7 @@ import torch +import fedscale.core.config_parser as parser from fedscale.core import commons from fedscale.core.aggregation.aggregator import Aggregator from fedscale.core.channels import job_api_pb2 @@ -504,5 +505,5 @@ def event_monitor(self): time.sleep(0.1) if __name__ == "__main__": - aggregator = AsyncAggregator(args) + aggregator = AsyncAggregator(parser.args) aggregator.run() diff --git a/examples/async_fl/async_executor.py b/examples/async_fl/async_executor.py index 991881af..eb02bcc0 100644 --- a/examples/async_fl/async_executor.py +++ b/examples/async_fl/async_executor.py @@ -2,6 +2,7 @@ import pickle import fedscale.core.channels.job_api_pb2 as job_api_pb2 +import fedscale.core.config_parser as parser from fedscale.core.execution.executor import Executor from fedscale.core.execution.rlclient import RLClient from fedscale.core.logger.execution import * @@ -167,5 +168,5 @@ def event_monitor(self): self.client_ping() if __name__ == "__main__": - executor = AsyncExecutor(args) + executor = AsyncExecutor(parser.args) executor.run() diff --git a/examples/differential_privacy/customized_executor.py b/examples/differential_privacy/customized_executor.py index 384eeb7f..56e2d987 100644 --- a/examples/differential_privacy/customized_executor.py +++ b/examples/differential_privacy/customized_executor.py @@ -6,7 +6,7 @@ from customized_client import Customized_Client from fedscale.core.execution.executor import Executor -from fedscale.core.logger.execution import args +import fedscale.core.config_parser as parser """In this example, we only need to change the Client Component we need to import""" @@ -21,6 +21,6 @@ def get_client_trainer(self, conf): return Customized_Client(conf) if __name__ == "__main__": - executor = Customized_Executor(args) + executor = Customized_Executor(parser.args) executor.run() diff --git a/examples/dry_run/customized_executor.py b/examples/dry_run/customized_executor.py index eac796a6..f6270ccb 100644 --- a/examples/dry_run/customized_executor.py +++ b/examples/dry_run/customized_executor.py @@ -6,7 +6,7 @@ from customized_client import Customized_Client from fedscale.core.execution.executor import Executor -from fedscale.core.logger.execution import args +import fedscale.core.config_parser as parser """In this example, we only need to change the Client Component we need to import""" @@ -21,5 +21,5 @@ def get_client_trainer(self, conf): return Customized_Client(conf) if __name__ == "__main__": - executor = Customized_Executor(args) + executor = Customized_Executor(parser.args) executor.run() \ No newline at end of file diff --git a/examples/heterofl/customized_aggregator.py b/examples/heterofl/customized_aggregator.py index eff99cef..9e5243e0 100644 --- a/examples/heterofl/customized_aggregator.py +++ b/examples/heterofl/customized_aggregator.py @@ -5,6 +5,7 @@ import customized_fllibs from customized_fllibs import make_param_idx +import fedscale.core.config_parser as parser from fedscale.core.aggregation.aggregator import Aggregator from fedscale.core.logger.aggragation import * @@ -118,5 +119,5 @@ def combine_models(self): if __name__ == "__main__": - aggregator = Customized_Aggregator(args) + aggregator = Customized_Aggregator(parser.args) aggregator.run() \ No newline at end of file diff --git a/examples/heterofl/customized_executor.py b/examples/heterofl/customized_executor.py index 7e2423f3..63111f43 100644 --- a/examples/heterofl/customized_executor.py +++ b/examples/heterofl/customized_executor.py @@ -4,7 +4,7 @@ from customized_client import Customized_Client from customized_fllibs import init_model -from fedscale.core.config_parser import args +import fedscale.core.config_parser as parser from fedscale.core.execution.executor import Executor @@ -24,5 +24,5 @@ def init_model(self): if __name__ == "__main__": - executor = Customized_Executor(args) + executor = Customized_Executor(parser.args) executor.run() \ No newline at end of file diff --git a/examples/poisoning_setting/customized_executor.py b/examples/poisoning_setting/customized_executor.py index 384eeb7f..b2e71047 100644 --- a/examples/poisoning_setting/customized_executor.py +++ b/examples/poisoning_setting/customized_executor.py @@ -5,8 +5,9 @@ from customized_client import Customized_Client +import fedscale.core.config_parser as parser from fedscale.core.execution.executor import Executor -from fedscale.core.logger.execution import args + """In this example, we only need to change the Client Component we need to import""" @@ -21,6 +22,6 @@ def get_client_trainer(self, conf): return Customized_Client(conf) if __name__ == "__main__": - executor = Customized_Executor(args) + executor = Customized_Executor(parser.args) executor.run() diff --git a/examples/tensorflow_engine/tf_aggregator.py b/examples/tensorflow_engine/tf_aggregator.py index ccbdb2d8..7a05aac6 100644 --- a/examples/tensorflow_engine/tf_aggregator.py +++ b/examples/tensorflow_engine/tf_aggregator.py @@ -3,6 +3,7 @@ import tensorflow as tf +import fedscale.core.config_parser as parser from fedscale.core.aggregation.aggregator import Aggregator from fedscale.core.logger.aggragation import * @@ -29,5 +30,5 @@ def init_model(self): } if __name__ == "__main__": - aggregator = Customized_Aggregator(args) + aggregator = Customized_Aggregator(parser.args) aggregator.run() \ No newline at end of file diff --git a/examples/tensorflow_engine/tf_executor.py b/examples/tensorflow_engine/tf_executor.py index af366f1a..4e25af60 100644 --- a/examples/tensorflow_engine/tf_executor.py +++ b/examples/tensorflow_engine/tf_executor.py @@ -6,6 +6,7 @@ import tensorflow as tf from tf_client import Customized_Client +import fedscale.core.config_parser as parser from fedscale.core.execution.executor import Executor from fedscale.core.logger.execution import * @@ -35,6 +36,6 @@ def init_model(self): if __name__ == "__main__": - executor = Customized_Executor(args) + executor = Customized_Executor(parser.args) executor.run()