This repo contains all source code that reproduce the experiments in our paper: Data-driven Inverse Optimization with Incomplete Information paper.
We welcome any feedback and suggestions! Note that we put in maximum effort to write high quality codes. However, they may still contain bugs or not be efficient enough.
All optimization problems are implemented in MATLAB. The implementations rely on the following third-party software: CPLEX Studio, MOSEK, and YALMIP. t is necessary to install these software and add their respective directories to the MATLAB path before running the codes.
CPLEX is a solver for mixed-integer linear, quadratic and second-order cone programs. In our implementations, we use CPLEX 12.6 via the ILOG C++ interface. All C++ codes are compiled into MEX binaries, which can be called from MATLAB. In Windows, the MEX binaries are generated using Microsoft Visual Studio (VS) compiler (see here for more information) . To generate the MEX binaries, you need to run
> make(CPLEX_root_directory)
in MATLAB command windows.
YALMIP is used to interface with MOSEK. To add YALMIP directories to the MATLAB path, you need to run. You can download it from here or its git repo. YALMIP is used to interface with MOSEK. To add YALMIP directories to the MATLAB path, you need to run
> addpath(genpath(YALMIP_root_directory))
You can download MOSEK from its website. Free versions for academia are available. You can add MOSEK directories to your MATLAB path by running
> addpath(MOSEK_root_directory\MATLAB_version)
Note: You can use the savepath command in MATLAB to save the YALMIP and MOSEK paths permanently. Otherwise, you will need to run the above addpath commands whenever you restart MATLAB.
First, clone the repo
$ git clone https://github.com/sorooshafiee/InverseOptimization.git
Then run
> make(CPLEX_root_directory)
in MATLAB command window. To reproduce the simulation results, you need to run m-file scripts.