Skip to content

Saurabh-29/Inverse_Optimization_To_Feasibility_To_ERM

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

From Inverse Optimization to Feasibility to ERM

This codebase contains implementation for all the methods and experiments in the paper (Ours, MOM, ST, BB and QPTL).

To run this code, there are three main steps.

Installation:

Install the conda environment from the environment.yaml file.

conda env create --file=environment.yaml

Data-generation

To generate synthetic data, run the Data/generate_dataset.py with the required config file. Default config is in config/configDataGen.yaml. Parameters can be overwritten at runtime from terminal.

cd Data
python synthetic_generator.py dataGen=sp

This generates shortest path synthetic data with default parameters in config/dataGen/sp.yaml file. To generate knapsack data, run the same script with dataGen=knapsack.

To generate the warcraft shortest path, mnist perfect matching, first download the dataset from this repository.

After downloading the dataset, run the corresponding generator file to generate the dataset in the form required by the code.

Running the method

To run the code for our method for a dataset with adagrad optimizer and lr=1.0

cd train
python train.py data_path=<path to data>  optimizer=adagrad optimizer.lr=1.0 method=revgrad

To run other method, replace revgrad with other method. When running perfect matching, use normalize_data=False

About

Code for ICML paper: From Inverse Optimization to Feasibility to ERM

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published