Unfolded D-ADMM for LASSO at agent p in iteration k. Dashed green and blue blocks are the primal and dual updates, respectively. Red fonts represent trainable parameters
Unfolded D-ADMM for linear regression model illustration at agent p in iteration k. Dashed green and blue blocks are the primal update and the dual update, respectively. Red fonts represent trainable parameters
In this work we propose a method that solves disributed optimization problem called Unfolded Distibuted Method of Multipliers(D-ADMM), which enables D-ADMM to operate reliably with a predefined and small number of messages exchanged by each agent using the emerging deep unfolding methodology. Unfolded D-ADMM fully preserves the operation of D-ADMM, while leveraging data to tune the hyperparameters of each iteration of the algorithm.
Please refer to our paper for more detailes.
This code has been tested on Python 3.9.7, PyTorch 1.10.2 and CUDA 11.1
- scipy
- tqdm
- numpy
- pytorch: https://pytorch.org
- matplotlib
- networknx
- TensorboardX: https://github.com/lanpa/tensorboardX
Example with 50 agents:
''' python dlasso.py --exp_name dlasso_with_50_agents --data simulated --batch_size 100 --P 50 --graph_prob 0.12 --case dlasso --model diff --valid True '''
or
''' python dlr.py --exp_name dlasso_with_50_agents --data simulated --batch_size 100 --P 50 --graph_prob 0.12 --case dlasso --model diff --valid True '''
Example with 50 agents:
''' python dlasso.py --exp_name dlasso_with_50_agents --eval --valid False '''
or
''' python dlr.py --exp_name dlasso_with_50_agents --eval --valid False
'''
Please refer to the data for the distributed LASSO problem.
The folder contains four directories for different SNR values {-2, 0, 2, 4}, in each directory there is a dataset_{snr}_snr.npy file which contain the data and labels.
When you load the data set allow_pickle=True.
For the distributed linear regression problem I used MNIST dataset.