diff --git a/docs/source/examples/md/fl_benchmark.png b/docs/source/examples/md/fl_benchmark.png index 12228a4c6a5312d3a376afd50e61601ac1360100..500034a272dfe6d177439ca4bd6ecaf5698a8afe 100644 Binary files a/docs/source/examples/md/fl_benchmark.png and b/docs/source/examples/md/fl_benchmark.png differ diff --git a/docs/source/examples/md/gru4rec_examples.md b/docs/source/examples/md/gru4rec_examples.md index 6e717aa85a81e1965f434093d0a8b064d379c7e0..9b4b827ddfba47320c071aecadf3fba66bb0b3c1 100644 --- a/docs/source/examples/md/gru4rec_examples.md +++ b/docs/source/examples/md/gru4rec_examples.md @@ -1,4 +1,4 @@ -# Train gru4rec model with FedAvg Strategy +# Example to train gru4rec model with FedAvg Strategy This doc introduce how to use PaddleFL to train model with Fl Strategy. @@ -16,7 +16,7 @@ python setup.py install ### Datasets -We use [Rsc15](https://2015.recsyschallenge.com) dataset as our data. +Public Dataset [Rsc15](https://2015.recsyschallenge.com) ```sh #download data @@ -27,6 +27,10 @@ sh download.sh ### How to work in PaddleFL PaddleFL has two period , CompileTime and RunTime. In CompileTime, define a federated learning task by fl_master. In RunTime, train a federated learning job by fl_server and fl_trainer . +```sh +sh run.sh +``` + ### How to work in CompileTime In this example, we implement it in fl_master.py ```sh @@ -70,7 +74,7 @@ python -u fl_server.py >server0.log & python -u fl_trainer.py 0 data/ >trainer0.log & python -u fl_trainer.py 1 data/ >trainer1.log & ``` -fl_trainer.py define the reader. +fl_trainer.py can define own reader according to data. ```python r = Gru4rec_Reader() train_reader = r.reader(train_file_dir, place, batch_size=10) @@ -87,18 +91,17 @@ wget https://paddle-zwh.bj.bcebos.com/gru4rec_paddlefl_benchmark/gru4rec_benchma | Dataset | single/distributed | distribute mode | recall@20| | --- | --- | --- |---| | all data | single | - | 0.508 | -| all data | distributed 4 node | parameter server | 0.501 | +| all data | distributed 4 node | Parameter Server | 0.504 | | all data | distributed 4 node | FedAvg | 0.504 | | 1/4 part-0 | single | - | 0.286 | | 1/4 part-1 | single | - | 0.277 | | 1/4 part-2 | single | - | 0.269 | | 1/4 part-3 | single | - | 0.282 | +We can find Distributed mode PS and FedAvg is equal in recall@20 , and more data could offer better result. + -


-fl benchmark -