cortex-lab / Suite2P

Tools for processing 2P recordings
Other
121 stars 66 forks source link

Error when using gui2p -- classifier not learning #114

Closed carlyrosewilling closed 6 years ago

carlyrosewilling commented 6 years ago

Hello there, while attempting to train a classifier in order to enhance automatic cell detection, I receive the following error whenever I try to save the plane:

Reference to non-existent field 'prior'. Error in new_main>pushbutton84_Callback (line 254) prior = h.prior; Error in gui_mainfcn (line 95) feval(varargin{:}); Error in new_main (line 17) gui_mainfcn(gui_State, varargin{:}); Error in matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)new_main('pushbutton84_Callback',hObject,eventdata,guidata(hObject)) Error while evaluating UIControl Callback.

a plane with _proc has been saved, but after several hundred hand selected ROIs, the classifier does not seem to be improving. When creating the new classifier, I clicked the following on the GUI. Load plane > selected F*.mat > new classifier > prior > (renamed to new cl). After hand selecting ROIs, I click the file save button, and when working with the classifier again, I click the choose classifier button and select it from the list.

Essentially, I believe the error message I am receiving is prohibiting the classifier from adequately being trained. Is there a problem with the way I am approaching training the classifier? Thank you in advance!!

carsen-stringer commented 6 years ago

sorry I think I messed up the classifier when I added in threshold values. I'm going to roll back the GUI now and add in the cell number to the stats area of the GUI so that when you click on a cell you can see it's number in the lower left part of the GUI.

carsen-stringer commented 6 years ago

I think the issue was actually that I had put different classifiers that used different statistics in the same folder and they were clashing. I'm sorry about that. I've cleared out that directory. You should be able to make a new classifier and then save it when you hit proc.

But the hard thresholds that I've added will mess with the training of the classifier. So please either use the classifier or the hard thresholds for choosing cells.

Let me know if it's still giving you trouble, sorry for the issues.