Skip to content

Commit

Permalink
Merge pull request #5 from jeremymchacon/master
Browse files Browse the repository at this point in the history
2 small commits to fix path issues and make more specific setup.py for pypi
  • Loading branch information
djbajic authored Sep 15, 2020
2 parents f42ce67 + c9c0230 commit 0d49126
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 13 deletions.
19 changes: 11 additions & 8 deletions cometspy/comets.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,16 @@ def __init__(self, layout, parameters, working_dir=''):
try:
self.GUROBI_HOME = os.environ['GUROBI_HOME']
except:
self.GUROBI_HOME = ''
print("could not find environmental variable GUROBI_COMETS_HOME or GUROBI_HOME")
print("COMETS will not work with GUROBI until this is solved. ")
print("Here is a solution:")
print(" 1. import os and set os.environ['GUROBI_HOME'] then try to make a comets object again")
print(" e.g. import os")
print(" os.environ['GUROBI_HOME'] = 'C:\\\\gurobi902\\\\win64'")
try:
self.GUROBI_HOME = os.environ['COMETS_GUROBI_HOME']
except:
self.GUROBI_HOME = ''
print("could not find environmental variable GUROBI_COMETS_HOME or GUROBI_HOME or COMETS_GUROBI_HOME")
print("COMETS will not work with GUROBI until this is solved. ")
print("Here is a solution:")
print(" 1. import os and set os.environ['GUROBI_HOME'] then try to make a comets object again")
print(" e.g. import os")
print(" os.environ['GUROBI_HOME'] = 'C:\\\\gurobi902\\\\win64'")
self.COMETS_HOME = os.environ['COMETS_HOME']
self.VERSION = os.path.splitext(os.listdir(os.environ['COMETS_HOME'] +
'/bin')[0])[0]
Expand Down Expand Up @@ -248,7 +251,7 @@ def run(self, delete_files=True):
# ' -Djava.library.path=' + self.D_JAVA_LIB_PATH +
' edu.bu.segrelab.comets.Comets -loader' +
' edu.bu.segrelab.comets.fba.FBACometsLoader' +
' -script ' + c_script)
' -script "' + c_script + '"')
p = sp.Popen(self.cmd, shell=True, stdout=sp.PIPE, stderr=sp.STDOUT)

self.run_output, self.run_errors = p.communicate()
Expand Down
7 changes: 2 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,11 @@
# I get to this in a second
'numpy',
'cobra',
'pandas'],
'pandas>=1.0.0'],
classifiers=[
'Development Status :: 4 - Beta', # "3 - Alpha", "4 - Beta", "5 - Production/Stable"
'Intended Audience :: Science/Research', # Define that your audience are developers
'License :: OSI Approved :: MIT License', # Again, pick a license
'Programming Language :: Python :: 3', # Supported pyhton versions
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
Expand Down

0 comments on commit 0d49126

Please sign in to comment.