JinghaoLu / MIN1PIPE

A MINiscope 1-photon-based Calcium Imaging Signal Extraction PIPEline.
GNU General Public License v3.0
56 stars 25 forks source link

normalize function has same name as internal matlab function #54

Closed martinjendryka closed 3 years ago

martinjendryka commented 3 years ago

Hi Jinghao, could you change the name of your function 'normalize', please? It has the same name as an internal matlab function (from matlab 2017 onwards). I found 'normalize' in the following sections, but probably there are more:

in min1pipe.m %%% estimate df/f %%% imcur = normalize(imaxy1); imref = normalize(imaxy);

in frame_reg.m maxallc = normalize(imaxn . knl); maskc = normalize(imgaussfilt(feature2_comp(maxallc, 0, 100, 5), 100 size(maxallc) / max(size(maxallc)))) > 0.4;

in get_trans_score.m

Best regards, Martin

JinghaoLu commented 3 years ago

Hi Martin,

Sorry for the late reply. There are many uses of normalize, so it would be almost impossible to do so without causing some bugs, if I had to do it recently. However, the inputs for the two functions are different, so if you need to use matlab normalize, you might need to always use "normalize(__, method)" by providing the default method argument, as a temporal solution.

martinjendryka commented 3 years ago

Thanks for the reply. that is understandable. I will close the issue then.