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

read grid file path from recipe if provided #205

Merged
merged 2 commits into from
Oct 19, 2023
Merged
Changes from 1 commit
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
Prev Previous commit
check if specified grid file exists, fall back to default if not
  • Loading branch information
mogres committed Oct 18, 2023
commit 2d00f18f543e40532db7f82c18296456dee793e8
3 changes: 2 additions & 1 deletion cellpack/autopack/Environment.py
Original file line number Diff line number Diff line change
@@ -157,7 +157,8 @@ def __init__(self, config=None, recipe=None):
f"{self.out_folder}/{self.name}_{config['name']}_{self.version}_grid.dat"
)
if recipe.get("grid_file_path") is not None:
self.grid_file_out = recipe["grid_file_path"]
if os.path.isfile(recipe["grid_file_path"]):
self.grid_file_out = recipe["grid_file_path"]

should_load_grid_file = (
os.path.isfile(self.grid_file_out) and self.load_from_grid_file
Loading