Allow relative paths in Arkane statmech#1685
Merged
Conversation
6903ac0 to
b9de5ca
Compare
Codecov Report
@@ Coverage Diff @@
## master #1685 +/- ##
=======================================
Coverage 41.66% 41.66%
=======================================
Files 176 176
Lines 30215 30215
Branches 6256 6256
=======================================
Hits 12588 12588
Misses 16703 16703
Partials 924 924Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #1685 +/- ##
=======================================
Coverage 32.65% 32.65%
=======================================
Files 87 87
Lines 26158 26158
Branches 6874 6874
=======================================
Hits 8541 8541
+ Misses 16656 16645 -11
- Partials 961 972 +11
Continue to review full report at Codecov.
|
b9de5ca to
05824e0
Compare
05824e0 to
7659aa3
Compare
Member
Author
|
@goldmanm, this PR should be relatively easy. Do you mind taking a look? (rebased on the Py3 master) |
Contributor
|
Will look at it today.
…On September 25, 2019 2:40:17 PM EDT, Alon Grinberg Dana ***@***.***> wrote:
@goldmanm, this PR should be relatively easy. Do you mind taking a
look? (rebased on the Py3 master)
--
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub:
#1685 (comment)
--
Sent from my Android device with K-9 Mail. Please excuse my brevity.
|
7659aa3 to
5f32f40
Compare
goldmanm
approved these changes
Sep 26, 2019
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation or Problem
Previously Arkane joined the base path of the species file with any statmech file (ESS output) path, assuming that the paths to the statmech files are relative to the species file directory.
In StatMechJob.load(),
pathis the path to the Arkane specie file, anddirectoryis the base path ofpath. When we read an ESS log file we joindirectoryand its path, e.g.:os.path.join(directory, energy.path). However, ifenergy.pathis a relative path (of the single point calculation output file), Arkane won't be able find the latter due to this path manipulation.Description of Changes
All statmech files specified by users (energy, geometry, frequency, scans) are now first checked to see if they exist, if not we relate to them as relative to
directory(and if that doesn't work, we raise an error).Testing
Added a test for absolute paths (fails on master)
Reviewer Tips
See that the code makes sense, try specifying an absolute path in a species statmech file and run on this branch (should fail on master)
(edited)