From 6d778eb3ed800bff229a7e93ac3d7c7f7cae09cb Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Sun, 26 May 2024 23:43:46 +0200 Subject: Fix bug in ParametrizeExprMixin --- polymatrix/expression/mixins/parametrizeexprmixin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/polymatrix/expression/mixins/parametrizeexprmixin.py b/polymatrix/expression/mixins/parametrizeexprmixin.py index 0676cea..644198e 100644 --- a/polymatrix/expression/mixins/parametrizeexprmixin.py +++ b/polymatrix/expression/mixins/parametrizeexprmixin.py @@ -43,7 +43,7 @@ class ParametrizeExprMixin(ExpressionBaseMixin): # FIXME: not sure this behaviour is intuitive, discuss if v := state.get_variable_from_name_or(self.name, if_not_present=False): - start, end = state.offset_dict[self.name] + start, end = state.offset_dict[v] if (nrows * ncols) != (end - start): raise ValueError("Cannot parametrize {self.underlying} with variable {v} " "found in state object, because its shape {(nrow, ncols)} " -- cgit v1.2.1