Skip to content

Commit

Permalink
Added 'default' and 'none' to IO Module hierarchy parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
sgriswol committed Jul 1, 2020
1 parent 9efc342 commit 159ea3d
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions python/asteria/IO.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,17 @@ def find(group, config):
condition = '&'.join( statements )
pass_interactions = set( row.nrow for row in tab_interactions.where(condition))

# Find Simulations that have the requested Hierarchy
pass_hierarchy = set( row.nrow for row in tab_hierarchy.where(config.simulation.hierarchy))
# Find Simulations that have the requested Hierarchy
pass_hierarchy = set()
if config.simulation.hierarchy is None:
pass_hierarchy = set(row.nrow for row in tab_hierarchy.where('none'))
else:
if config.simulation.hierarchy.lower() in ['none', 'no']:
pass_hierarchy = set(row.nrow for row in tab_hierarchy.where('none'))
elif config.simulation.hierarchy.lower() in ['normal', 'default']:
pass_hierarchy = set(row.nrow for row in tab_hierarchy.where('normal'))
elif config.simulation.hierarchy.lower() in ['inverted']:
pass_hierarchy = set(row.nrow for row in tab_hierarchy.where('inverted'))

# Find Simulations that have the requested flavors
statements = []
Expand Down

0 comments on commit 159ea3d

Please sign in to comment.