kushalkolar / MESmerize

Platform for Calcium Imaging analysis. DEPRECATED.
GNU General Public License v3.0
59 stars 14 forks source link

CNMFE goes to orange #16

Closed maxrioux100 closed 3 years ago

maxrioux100 commented 4 years ago

Hello, Still trying to figure out how to make mesmerize work. Now when I run the CNMFE it always end up orange. From the logs, it look like it finished but its still not green. I checked your documentation and orange means that the user aborted it but I didn't

Screenshot from 2020-05-22 13-36-57

kushalkolar commented 4 years ago

I think this is a bug when you have just one batch item. If you seen high CPU/RAM usage then CNMFE is occuring

maxrioux100 commented 4 years ago

Where can I see the result?

kushalkolar commented 4 years ago

Double click the batch item

maxrioux100 commented 4 years ago

Ok I ran it in a batches of 2 items, the first one resolved but now the cnmfe is red. Here is the output. Screenshot from 2020-05-22 18-06-48

kushalkolar commented 4 years ago

Seems like it has something to do with your image data and/or parameters

maxrioux100 commented 4 years ago

This is what I was thinking but I cant set the parameters exactly like on my test directly with caiman. K=none or nb_patch=0(The interface doesnt allow me). Do you have any idea why some negative dimension would appear ?

kushalkolar commented 4 years ago

No idea sorry. The caiman supplied with mesmerize is a bit older, I'm currently working on updating mesmerize to be more up to date with caiman.

maxrioux100 commented 4 years ago

Alright, is there a way to use the output from a more recent caiman and import them in Mesmerize for now ?

kushalkolar commented 4 years ago

Something like this in the viewer console might work if the CNMF data are still the same types of objects in newer versions of caiman:

get_module('roi_manager').start_cnmfe_mode()
get_module('roi_manager').manager.add_all_components(<args, kwargs>)

See http://mesmerizelab.org/api_reference/viewer_modules/roi_manager.html#mesmerize.viewer.modules.roi_manager_modules.managers.ManagerCNMFE.add_all_components

maxrioux100 commented 4 years ago

Sorry for the delay, it was the weekend. Did you implement a way to do this directly with a .hdf5 file or do I need to code this function ? I'm asking since CaImAn output this info in those file and I think it could benefit for the users of your application.

kushalkolar commented 4 years ago

Yes I will try to have a way to import from Caiman hdf5 output files.

kushalkolar commented 4 years ago

@maxrioux100 This is now possible with mesmerize versions >= 0.2.0: https://mesmerize.readthedocs.io/en/master/user_guides/viewer/modules/caiman_hdf5_importer.html

You can install it through pip: https://github.com/kushalkolar/MESmerize#installation