Skip to content

Commit

Permalink
Bugfix - directly inputing energy to arkane species
Browse files Browse the repository at this point in the history
This commit checks to make sure energy is a Log object before
trying to access energy.path, since energy can also be a float in
hartrees or a tuble with various units
  • Loading branch information
goldmanm committed Nov 5, 2019
1 parent 5ada85f commit cba4f3f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arkane/statmech.py
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ def load(self, pdep=False, plot=False):
except KeyError:
raise InputError('Model chemistry {0!r} not found in from dictionary of energy values in species file '
'{1!r}.'.format(self.modelChemistry, path))
if not os.path.isfile(energy.path):
if isinstance(energy, Log) and not os.path.isfile(energy.path):
modified_energy_path = os.path.join(directory, energy.path)
if not os.path.isfile(modified_energy_path):
raise InputError('Could not find single point energy file for species {0} '
Expand Down

0 comments on commit cba4f3f

Please sign in to comment.