Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
djinnome committed Oct 23, 2024
1 parent a87e243 commit bab0444
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pyciemss/mira_integration/distributions.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@ def sort_mira_dependencies(src: mira.metamodel.TemplateModel) -> list:
for param_info in src.parameters.values():
param_name = param_info.name
param_dist = getattr(param_info, "distribution", None)
# Check to see if the distribution parameters are sympy expressions
if param_dist is not None:
for k, v in param_dist.parameters.items():
# Check to see if the distribution parameters are sympy expressions
# and add their free symbols to the dependency graph
if isinstance(v, mira.metamodel.utils.SympyExprStr):
for free_symbol in v.free_symbols:
dependencies.add_edge(str(free_symbol), str(param_name))
Expand Down

0 comments on commit bab0444

Please sign in to comment.