GithubHelp home page GithubHelp logo

Comments (2)

schoinh avatar schoinh commented on June 10, 2024

Traceback:

~/Projects/napari-aicssegmentation/napari_aicssegmentation/controller/workflow_select_controller.py in _handle_layers_change(self=<napari_aicssegmentation.controller.workflow_select_controller.WorkflowSelectController object>, e=<Event blocked=False handled=False native=None source=None sources=[] type=layers_change>)
    106         """
    107         self.model.layers = self._get_3D_layers()
--> 108         self._view.update_layers(self.model.layers, self.model.selected_layer)
        self._view.update_layers = <bound method WorkflowSelectView.update_layers of <napari_aicssegmentation.view.workflow_select_view.WorkflowSelectView object at 0x7f95f8b28040>>
        self.model.layers = ['test_sample_single', '0. test_sample_single: ch[0] actb', '0. 0. test_sample_single: ch[0] actb: ch[0] actb']
        self.model.selected_layer = <Image layer '0. test_sample_single: ch[0] actb' at 0x7f95e8fa6f70>
    109 
    110         if self.model.selected_layer is None or self.model.selected_layer.name not in self.model.layers:

~/Projects/napari-aicssegmentation/napari_aicssegmentation/view/workflow_select_view.py in update_layers(self=<napari_aicssegmentation.view.workflow_select_view.WorkflowSelectView object>, layers=['test_sample_single', '0. test_sample_single: ch[0] actb', '0. 0. test_sample_single: ch[0] actb: ch[0] actb'], selected_layer=<Image layer '0. test_sample_single: ch[0] actb'>)
     97         pyqtRemoveInputHook()
     98         pdb.set_trace()
---> 99         self._reset_combo_box(self.combo_layers)
        self._reset_combo_box = <bound method WorkflowSelectView._reset_combo_box of <napari_aicssegmentation.view.workflow_select_view.WorkflowSelectView object at 0x7f95f8b28040>>
        self.combo_layers = <PyQt5.QtWidgets.QComboBox object at 0x7f95f8b28670>
    100 
    101         if layers is None or len(layers) == 0:

~/Projects/napari-aicssegmentation/napari_aicssegmentation/view/workflow_select_view.py in _reset_combo_box(self=<napari_aicssegmentation.view.workflow_select_view.WorkflowSelectView object>, combo=<PyQt5.QtWidgets.QComboBox object>)
    158         Reset a combo box to its original state, keeping the header but removing all other items
    159         """
--> 160         if combo.count() > 0:
        combo.count = <built-in method count of QComboBox object at 0x7f95f8b28670>
    161             header = combo.itemText(0)
    162             combo.clear()

RuntimeError: wrapped C/C++ object of type QComboBox has been deleted

I looked into this and it might not be a quick fix… I think it may have to do with Qt garbage collection, and also found someone else who seemed to be having the same kind of issue on Zulip while developing their own layer manager.

Also a similar-sounding problem in the napari repo: napari/napari#2238

from napari-allencell-segmenter.

schoinh avatar schoinh commented on June 10, 2024

Here's something that looks like it could be a very helpful explanation: http://enki-editor.org/2014/08/23/Pyqt_mem_mgmt.html (I haven't had a chance to read it thoroughly / apply its wisdoms yet)

from napari-allencell-segmenter.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.