From 5016eb5da5c3884f1386bb39420cc61dd6f485ea Mon Sep 17 00:00:00 2001 From: Filip Macak Date: Sat, 27 Apr 2024 12:04:33 +0200 Subject: [PATCH] Fixed posterior aware export --- paynt/quotient/storm_pomdp_control.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/paynt/quotient/storm_pomdp_control.py b/paynt/quotient/storm_pomdp_control.py index 8af1c4562..f4fd24fca 100644 --- a/paynt/quotient/storm_pomdp_control.py +++ b/paynt/quotient/storm_pomdp_control.py @@ -700,6 +700,8 @@ def overapp_belief_value_analysis(self, number_of_beliefs): analysed_beliefs += 1 belief_obs = self.quotient.pomdp.get_observation(list(belief.keys())[0]) belief_value = self.compute_belief_value(belief, belief_obs, export_values) + if belief_value is None: + continue belief_values_dif[belief_id] = abs(self.belief_overapp_values[belief_id] - belief_value) if belief_obs not in obs_differences.keys(): @@ -790,7 +792,10 @@ def parse_paynt_result(self, quotient): if name.startswith('M'): continue name = name.strip('A()') - obs = name.split(',')[0] + if not paynt.quotient.pomdp.PomdpQuotient.posterior_aware: + obs = name.split(',')[0] + else: + obs = name.split(',')[1] observation = self.quotient.observation_labels.index(obs) option = self.latest_paynt_result.hole_options(hole)[0]