petter2025 commited on
Commit
5a8b861
·
verified ·
1 Parent(s): 04ce62b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -1
app.py CHANGED
@@ -49,8 +49,13 @@ except ImportError:
49
  # ----------------------------------------------------------------------
50
  # Infrastructure simulator and engines
51
  # ----------------------------------------------------------------------
52
- infra_sim = AzureInfrastructureSimulator(policy=policy_engine)
53
  policy_engine = PolicyEngine() # loads default policies
 
 
 
 
 
54
  risk_engine = RiskEngine(hmc_model_path="hmc_model.json", use_hyperpriors=True)
55
 
56
  # ----------------------------------------------------------------------
 
49
  # ----------------------------------------------------------------------
50
  # Infrastructure simulator and engines
51
  # ----------------------------------------------------------------------
52
+ # Define policy_engine first
53
  policy_engine = PolicyEngine() # loads default policies
54
+
55
+ # Now create simulator, passing the policy_engine
56
+ infra_sim = AzureInfrastructureSimulator(policy=policy_engine)
57
+
58
+ # Risk engine (does not depend on policy_engine)
59
  risk_engine = RiskEngine(hmc_model_path="hmc_model.json", use_hyperpriors=True)
60
 
61
  # ----------------------------------------------------------------------