Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update path for pysp and update libraries in build.sh #48

Merged
merged 1 commit into from
Oct 20, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,9 @@ function install_libraries()
if [[ $ECE_VERBOSE == 0 ]]; then echo ... Installing libraries from conda-forge ...; fi
if [[ "$OSOPTION" = "--windows" ]];
then
local COMMAND=`echo conda install -c conda-forge pyomo ipopt glpk`
local COMMAND=`echo conda install -c conda-forge pyomo ipopt glpk pyutilib numpy-financial`
else
local COMMAND=`echo conda install -c conda-forge pyomo ipopt coincbc glpk`
local COMMAND=`echo conda install -c conda-forge pyomo ipopt coincbc glpk pyutilib numpy-financial`
fi
if [[ $ECE_VERBOSE == 0 ]]; then echo ... conda-forge command: ${COMMAND}; fi
${COMMAND}
Expand All @@ -79,9 +79,9 @@ function create_libraries()
if [[ $ECE_VERBOSE == 0 ]]; then echo ... Installing libraries from conda-forge ...; fi
if [[ "$OSOPTION" = "--windows" ]];
then
local COMMAND=`echo conda install -n ${LOGOS_LIBS_NAME} -c conda-forge pyomo ipopt glpk`
local COMMAND=`echo conda install -n ${LOGOS_LIBS_NAME} -c conda-forge pyomo ipopt glpk pyutilib numpy-financial`
else
local COMMAND=`echo conda install -n ${LOGOS_LIBS_NAME} -c conda-forge pyomo ipopt coincbc glpk`
local COMMAND=`echo conda install -n ${LOGOS_LIBS_NAME} -c conda-forge pyomo ipopt coincbc glpk pyutilib numpy-financial`
fi
if [[ $ECE_VERBOSE == 0 ]]; then echo ... conda-forge command: ${COMMAND}; fi
${COMMAND}
Expand Down
10 changes: 5 additions & 5 deletions src/logos_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@

#Internal Modules------------------------------------------------------------------------------------
# Add contrib to the sys path
from _utils import getPluginLoc
pluginLoc = getPluginLoc(plugin='LOGOS')
if any(os.path.normcase(sp) == os.path.join(pluginLoc, 'src', 'contrib') for sp in sys.path):
print(f'WARNING: "{os.path.join(pluginLoc, "src", "contrib")}" already in system path. Skipping setup')
pyspLoc = os.path.abspath(os.path.join(os.path.dirname(__file__), 'contrib'))
if any(os.path.normcase(sp) == pyspLoc for sp in sys.path):
print(f'WARNING: "{pyspLoc}" already in system path. Skipping setup')
else:
sys.path.append(os.path.join(pluginLoc, 'src', 'contrib'))
sys.path.append(pyspLoc)

#import PyomoModels
from CapitalInvestments import PyomoModels
from CapitalInvestments.investment_utils import inputReader
Expand Down