Skip to content

Commit

Permalink
Quick fix for GH-373
Browse files Browse the repository at this point in the history
Move the call to `get_static_arguments` under the 'emcee' inference
branch. This avoids calling `outcomes.read_parameters_from_config`
twice. That function has a side effect of editing the outcome modifiers
config. See
#373 (comment)
for details.
  • Loading branch information
TimothyWillard committed Dec 4, 2024
1 parent 73d2a2f commit 980429e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions flepimop/gempyor_pkg/src/gempyor/inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -392,14 +392,14 @@ def __init__(
self.already_built = False # whether we have already built the costly objects that need just one build
self.autowrite_seir = autowrite_seir

self.static_sim_arguments = get_static_arguments(self.modinf)

## Inference Stuff
self.do_inference = False
if config["inference"].exists():
from . import inference_parameter, logloss

if config["inference"]["method"].get("default") == "emcee":
# Generates the static_sim_arguments only if this is a config argument.
self.static_sim_arguments = get_static_arguments(self.modinf)
self.do_inference = True
self.inference_method = "emcee"
self.inferpar = inference_parameter.InferenceParameters(
Expand Down

0 comments on commit 980429e

Please sign in to comment.