minaremeli / moon Goto Github PK
View Code? Open in Web Editor NEWMOON reproducibility study
MOON reproducibility study
Currently all new results overwrite old ones. Need a solution for saving results in different locations.
We want to use Docker to deploy and run experiments on any cloud platform quickly, and seamlessly.
Running the model with the following parameters does not learn even after 100 rounds of training (this code ran for a total of 1.5 hours on dev-gpu-0.cl.cam.ac.uk
โ I think this is less than expected).
python main.py --num_rounds 100 --sample_fraction_fit 1.0 --num_clients 10 --strategy fedAvg --beta 5
Very small changes (1e-3
and smaller) can be observed over time on the loss (CrossEntropyLoss
), but accuracy almost always stays a constant 0.1
. This is true for both local and global accuracies. I experienced the same when running for fewer rounds / different beta / num_clients / sample_fraction_fit / etc.
Possible causes:
I might need some help figuring this out @VasundharaAgarwal ๐
So far only accuracy has been calculated on evaluation (both centralized and distributed). Additionally, we could calculate the supervised loss (CrossEntropyLoss
) for debugging and evaluation purposes.
I have thought about calculating the contrastive loss in case of moon
strategy, but have decided against it. 1) The implementation would be messy in my opinion 2) Contrastive loss does not make sense to me when the global and the local model are the same 3) Logically CrossEntropyLoss
should decrease as well if implementation works
In each round we fit on fraction * num_clients
.
In each round we also evaluate on client's local dataset. Currently evaluation is calculated on a fix number of 2 clients.
Expected behaviour is not clear, and there are multiple options:
fraction * num_clients
(random sampling)fraction * num_clients
(SAME clients as before, when we fit the model)@VasundharaAgarwal what do you think?
After running an experiment, accuracies calculated on centralised and local data should be saved.
The corresponding files get created:
data/accs_centralized.npy
data/accs_distributed.npy
However, when loading them using np.load()
, we get an empty array array([], dtype=float64)
.
When running main.py --to_partition False
the boolean value is not set to False
, but to True
, because non-empty strings are True
in Python.
We recommend you focus on the central claim of the paper. For example, if a paper introduces a new RL learning algorithm that performs better in sparse-reward environments, verify that you can re-implement the algorithm, run it on the same benchmarks and get results that are close to those in the original paper (exact reproducibility is in most cases very difficult due to minor implementation details). You do not need to reproduce all experiments in your selected paper, but only those that you feel are sufficient for you to verify the validity of the central claim.
More information on the task here.
For reproducibility purposes, the code should execute the same with a fixed seed.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.