schnitzer-lab / EXTRACT-public

EXTRACT is a tractable and robust automated cell extraction tool for calcium imaging, which extracts the activities of cells as time series from both one-photon and two-photon calcium imaging movies.
MIT License
64 stars 17 forks source link

EXTRACT throws an error if avg_cell_radius is empty or a string #23

Closed bahanonu closed 2 years ago

bahanonu commented 2 years ago

@fatihdinc Can EXTRACT check that avg_cell_radius is not an empty vector or string/character? Else MATLAB throws the below error at https://github.com/schnitzer-lab/EXTRACT-public/blob/master/EXTRACT/helper_functions/spatial_bandpass.m#L52.

Error using  / 
Matrix dimensions must agree.

Potentially in extractor.m at lines https://github.com/schnitzer-lab/EXTRACT-public/blob/master/EXTRACT/solvers/extractor.m#L16-L18 this check could also occur and throw an error to make it explicit to users, similar to if avg_cell_radius option is not present.

fatihdinc commented 2 years ago

Thank you Biafra for bringing this into my attention. This check is now being made, please let me know if the issue still exists for you or feel free to close this issue!