Skip to content
Snippets Groups Projects
Commit 752fc5b2 authored by Erick Lavoie's avatar Erick Lavoie
Browse files

Added baseline experiment for mnist with 1000 nodes

parent 4de1e38b
No related branches found
No related tags found
No related merge requests found
......@@ -371,6 +371,11 @@ Appendix~\ref{app:scaling} for additional results comparing the convergence
speed across different number of nodes. Overall, these results
show that D-Cliques can nicely scale with the number of nodes.
% From directory 'results-v2':
% MNIST
% python $TOOLS/analyze/filter.py all --dataset:name mnist --topology:name d-cliques/greedy-swap --nodes:name 2-shards-uneq-classes --meta:seed 1 --nodes:nb-nodes 100 | python $TOOLS/analyze/diff.py
% python $TOOLS/analyze/diff.py --rundirs all/2021-09-30-11:39:47-CEST-labostrex114 all/2021-09-30-11:40:32-CEST-labostrex115 --pass-through | python $TOOLS/plot/convergence.py --add-min-max --ymin 84 --ymax 92.5 --yaxis test-accuracy --labels 'fully-connected' 'd-cliques (fractal)' 'd-cliques (ring)' --save-figure ../mlsys2022style/figures/d-cliques-scaling-mnist-1000-linear.png --linestyles 'solid' 'dashed' 'dotted' --font-size 18
\begin{figure}[t]
\centering
% % To regenerate the figure, from directory results/mnist
......
#!/usr/bin/env bash
# Path to current script
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
TOOLS=$SCRIPT_DIR/$(cat toolspath); cd $TOOLS
# Add current working directory to executable namespace
export PATH=$PATH:$TOOLS
# Setup root directory for resolution of imports:
# the path of all local python libraries are relative to this
export PYTHONPATH=$TOOLS
# Each command outputs the run directory, which is then used
# by the next command to add parameters and generate information
# used by the simulator. For a list of available options for each
# command, run 'export PYTHONPATH=.; <command> --help'.
for SEED in 1; do
setup/meta.py \
--results-directory $SCRIPT_DIR/tmp \
--seed $SEED |
setup/dataset.py \
--name mnist \
--train-examples-per-class 4943 5607 4926 5121 4860 4529 4960 5237 4877 4940 |
setup/nodes/google-fl.py \
--name 2-shards-uneq-classes \
--nb-nodes 1000 \
--local-shards 2 \
--shard-size 25 |
setup/topology/fully-connected.py |
setup/model/linear.py |
simulate/algorithm/d_sgd.py \
--batch-size 13 \
--learning-momentum 0.0 \
--learning-rate 0.1 |
simulate/logger.py \
--nb-processes 1 |
simulate/run.py \
--nb-epochs 100;
done
#!/usr/bin/env bash
# Path to current script
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
TOOLS=$SCRIPT_DIR/$(cat toolspath); cd $TOOLS
# Add current working directory to executable namespace
export PATH=$PATH:$TOOLS
# Setup root directory for resolution of imports:
# the path of all local python libraries are relative to this
export PYTHONPATH=$TOOLS
# Each command outputs the run directory, which is then used
# by the next command to add parameters and generate information
# used by the simulator. For a list of available options for each
# command, run 'export PYTHONPATH=.; <command> --help'.
for SEED in 1 2 3; do
setup/meta.py \
--script $SCRIPT_DIR/`basename "$0"` \
--results-directory $SCRIPT_DIR/tmp \
--seed $SEED |
setup/dataset.py \
--name mnist \
--train-examples-per-class 4500 4500 4500 4500 4500 4500 4500 4500 4500 4500 |
setup/nodes.py \
--name iid-eq-classes \
--nb-nodes 1 \
--local-classes 10 \
--nodes-per-class 1 1 1 1 1 1 1 1 1 1 |
setup/topology/fully-connected.py |
setup/model/linear.py |
simulate/algorithm/d_sgd.py \
--batch-size 12800 \
--learning-momentum 0.0 \
--learning-rate 0.1 |
simulate/logger.py \
--nb-processes 1 |
simulate/run.py \
--nb-epochs 100;
done
#!/usr/bin/env bash
# Path to current script
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
TOOLS=$SCRIPT_DIR/$(cat toolspath); cd $TOOLS
# Add current working directory to executable namespace
export PATH=$PATH:$TOOLS
# Setup root directory for resolution of imports:
# the path of all local python libraries are relative to this
export PYTHONPATH=$TOOLS
# Each command outputs the run directory, which is then used
# by the next command to add parameters and generate information
# used by the simulator. For a list of available options for each
# command, run 'export PYTHONPATH=.; <command> --help'.
for SEED in 1 2 3; do
setup/meta.py \
--script $SCRIPT_DIR/`basename "$0"` \
--results-directory $SCRIPT_DIR/tmp \
--seed $SEED |
setup/dataset.py \
--name mnist \
--train-examples-per-class 4943 5607 4926 5121 4860 4529 4960 5237 4877 4940 |
setup/nodes.py \
--name iid-uneq-classes \
--nb-nodes 1 \
--local-classes 10 \
--nodes-per-class 1 1 1 1 1 1 1 1 1 1 |
setup/topology/fully-connected.py |
setup/model/linear.py |
simulate/algorithm/d_sgd.py \
--batch-size 12800 \
--learning-momentum 0.0 \
--learning-rate 0.1 |
simulate/logger.py \
--nb-processes 1 |
simulate/run.py \
--nb-epochs 100;
done
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment