extrap icon indicating copy to clipboard operation
extrap copied to clipboard

SegmentedModeler experiment save bug

Open marcusritter1 opened this issue 1 year ago • 0 comments

When saving the results of a model created with the segmented modeler, when reloading using open experiment the following error comes up:

Commit 1945ffe of Branch #v4.2.0

$ Traceback (most recent call last): File "e:\extrap\extrap\gui\SelectorWidget.py", line 239, in model_changed self.main_widget.on_selection_changed() File "e:\extrap\extrap\gui\MainWidget.py", line 309, in on_selection_changed self.updateMinMaxValue() File "e:\extrap\extrap\gui\MainWidget.py", line 492, in updateMinMaxValue self.color_widget.update_min_max(*self.selector_widget.update_min_max_value()) File "e:\extrap\extrap\gui\SelectorWidget.py", line 351, in update_min_max_value value_list = self.iterate_children(model_set.models, param_value_list, nodes, selected_metric) File "e:\extrap\extrap\gui\SelectorWidget.py", line 328, in iterate_children formula = model.hypothesis.function AttributeError: 'NoneType' object has no attribute 'function' Traceback (most recent call last): File "e:\extrap\extrap\gui\MainWidget.py", line 584, in event return super().event(e) File "e:\extrap\extrap\gui\TreeModel.py", line 179, in data formula = model.hypothesis.function AttributeError: 'NoneType' object has no attribute 'function' Traceback (most recent call last): File "e:\extrap\extrap\gui\MainWidget.py", line 584, in event return super().event(e) File "e:\extrap\extrap\gui\GraphWidget.py", line 92, in paintEvent self.drawGraph(paint) File "e:\extrap\extrap\gui\GraphWidget.py", line 326, in drawGraph y = self.calculateMaxY(model_list) * 1.2 File "e:\extrap\extrap\gui\GraphWidget.py", line 838, in calculateMaxY y = max(model.predictions) File "C:\Users\ritte\AppData\Local\Programs\Python\Python310\lib\functools.py", line 981, in __get__ val = self.func(instance) File "e:\extrap\extrap\entities\model.py", line 37, in predictions return self.hypothesis.function.evaluate(coordinates.transpose()) AttributeError: 'NoneType' object has no attribute 'function'

Most likely an issue of how the functions/hypotheses are saved when doing I/O. # @

marcusritter1 avatar Jan 19 '24 14:01 marcusritter1