OptStoic python package
Perform optStoic analysis using Python code that share the same data files with GAMS code.
Note: All the examples are specific for glycolysis pathway generation.
git clone https://github.com/maranasgroup/optstoic-python.git cd optstoic-python python setup.py install
At least one of the following optimization solvers should be installed. To solve the loopless optStoic formulation, an optimization solver other than GLPK is recommended.
GLPK 4.47 installation
wget http://ftp.gnu.org/gnu/glpk/glpk-4.47.tar.gz tar -xvzf glpk-4.47.tar.gz cd ~/glpk-4.47 ./configure make make install #if the program is successfully installed, you should get an output by typing glpsol --version
GUROBI Optimization provide academic license for free (https://www.gurobi.com/). Install gurobipy following the instruction provided by GUROBI.
SCIP Optimization Suite >= v4.0.0
sudo apt-get install libgmp-dev libreadline-dev zlib1g-dev libncurses5-dev tar xvf scipoptsuite-6.0.0.tgz cd scipoptsuite-6.0.0/ make make test cd scip-6.0.0/ sudo make install INSTALLDIR="/usr/local/" /usr/local/bin/scip --version
Current project dependencies
pip install pulp
pip install pandas
Graphviz (Optional, for drawing pathway). The Graphviz software is required before installing the graphviz python package.
#If you have root access sudo apt-get install graphviz #If you do not have root access (you can get a different version of Graphviz from their website https://www.graphviz.org/download/) cd $HOME mkdir -p bin/graphviz wget http://www.graphviz.org/pub/graphviz/stable/SOURCES/graphviz-2.38.0.tar.gz tar xvf graphviz-2.38.0.tar.gz cd graphviz-2.38.0 ./configure --prefix=$HOME/bin/graphviz make && make install # Check if the graphviz is working cd $HOME/bin/graphviz/bin dot -V # Add the following line to your .bashrc export PATH=$PATH:$HOME/bin/graphviz/bin #Install the Python graphviz package pip install graphviz
Component-Contribution (*Optional, unless you want to perform MDF analysis)
After cloning the repo or setup, please run tests as followed:
pip install nose nosetests -s -v
To test the optimization algorithms, please run tests as followed. The runtime depends on the solvers selected by PuLP.
from optstoicpy.test.testAll import test_all_optimization_scripts test_all_optimization_scripts()
Read the tutorial.
To continue development with the code, please create a virtual environment and use
python setup.py develop for installation.
Please cite Chiam Yu Ng, Lin Wang, Anupam Chowdhury and Costas D. Maranas, 2018 (under review).