kachery-cloud
kachery-cloud copied to clipboard
`ModuleNotFoundError: No module named 'kachery_cloud.TaskBackend'` from figurl_jupyter
@alejoe91 could you provide some more details on when this error occurs? (seems like an old version of kachery cloud)
No this occurs with the new Kachery-cloud (0.4.2) when using the display function from figurl jupyter. Here's the full error stack:
---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
Input In [10], in <cell line: 1>()
----> 1 sw.plot_unit_locations(we, backend="sortingview", display=True)
File ~/Documents/codes/spike_sorting/spikeinterface/spikeinterface/src/spikeinterface/widgets/base.py:120, in define_widget_function_from_class.<locals>.widget_func(*args, **kwargs)
117 @copy_signature(widget_class)
118 def widget_func(*args, **kwargs):
119 W = widget_class(*args, **kwargs)
--> 120 W.do_plot(W.backend, **W.backend_kwargs)
121 return W.plotter
File ~/Documents/codes/spike_sorting/spikeinterface/spikeinterface/src/spikeinterface/widgets/base.py:53, in BaseWidget.do_plot(self, backend, **backend_kwargs)
51 plotter = self.possible_backends[backend]()
52 self.check_backend_kwargs(plotter, backend, **backend_kwargs)
---> 53 plotter.do_plot(self.plot_data, **backend_kwargs)
54 self.plotter = plotter
File ~/Documents/codes/spike_sorting/spikeinterface/spikeinterface/src/spikeinterface/widgets/sortingview/unit_locations.py:40, in UnitLocationsPlotter.do_plot(self, data_plot, **backend_kwargs)
37 else:
38 view = v_unit_locations
---> 40 self.handle_display_and_url(view, **backend_kwargs)
41 return view
File ~/Documents/codes/spike_sorting/spikeinterface/spikeinterface/src/spikeinterface/widgets/sortingview/base_sortingview.py:47, in SortingviewPlotter.handle_display_and_url(self, view, **backend_kwargs)
45 self.set_view(view)
46 if self.is_notebook() and backend_kwargs["display"]:
---> 47 display(self.view.jupyter(height=backend_kwargs["height"]))
48 if backend_kwargs["generate_url"]:
49 figlabel = backend_kwargs.get("figlabel")
File ~/anaconda3/envs/si/lib/python3.9/site-packages/sortingview/views/View.py:100, in View.jupyter(self, height)
98 if height is None:
99 height = self._height
--> 100 import figurl_jupyter as fj
101 url = self.url(label='jupyter', local=True, electron=False, listen_port=None)
102 a = _parse_figurl_url(url)
File ~/anaconda3/envs/si/lib/python3.9/site-packages/figurl_jupyter/__init__.py:7, in <module>
1 #!/usr/bin/env python
2 # coding: utf-8
3
4 # Copyright (c) Jeremy Magland.
5 # Distributed under the terms of the Modified BSD License.
----> 7 from .FigurlFigure import FigurlFigure
8 from ._version import __version__, version_info
10 def _jupyter_labextension_paths():
File ~/anaconda3/envs/si/lib/python3.9/site-packages/figurl_jupyter/FigurlFigure.py:17, in <module>
15 import kachery_cloud as kcl
16 from ._frontend import module_name, module_version
---> 17 from kachery_cloud.TaskBackend.TaskBackend import TaskHandler
18 from kachery_cloud._json_stringify_deterministic import _json_stringify_deterministic
19 from kachery_cloud._serialize import _serialize
ModuleNotFoundError: No module named 'kachery_cloud.TaskBackend'
Sorry! I stopped supporting jupyter widgets as part of sortingview -- nobody was using it as far as I could see, and it is difficult to maintain with various updates to jupyter. It's possible we could get this to work again by disabling the task backend part of it...
Ok, please let us know about these changes! In spikeinterface figurl_jupyter is a required package....honestly I think it was very usefule!
hi Jeremy. I also think that this is a veryuselfull feature because we can use the visualisation without pushing data which is very very convinient.