bahanonu / ciatah

CIAtah (pronounced cheetah): a software package for calcium imaging analysis of one- and two-photon imaging datasets. Documentation: https://git.io/ciatah_docs. Formerly known as calciumImagingAnalysis (ciapkg).
https://git.io/ciatah_docs
MIT License
80 stars 20 forks source link

Error with ciatah update modelpreprocessMovie #117

Closed Antorithms closed 1 year ago

Antorithms commented 1 year ago

Hi, I just updated to the most up to date version of ciatah but upon running modelpreprocessMovie to preprocess a .tif movie we run in the error below. We are running in MATLAB R2021b Let us know what could be the issue: the regex and video filename are corresponding (precisely 077_01, if this could in any way be the issue).

Running standard TIFF
@@@@@@@
Undefined function 'tiffread' for input arguments of type 'char'.

Error in ciapkg.io.load_tif_movie/standardTIFF_new (line 181)
            out.Movie = tiffread(filename,[],'ReadUnknownTags',1);

Error in ciapkg.io.load_tif_movie (line 85)
        standardTIFF_new();

Error in ciapkg.api.load_tif_movie (line 13)
    [out] = ciapkg.io.load_tif_movie(filename,downsample_xy,'passArgs', varargin);

Error in ciapkg.io.loadMovieList (line 643)
                        outputMovie = load_tif_movie(thisMoviePath,1,'displayInfo',options.displayInfo,'fileInfo',fileInfoH);

Error in ciapkg.api.loadMovieList (line 9)
    [outputMovie, movieDims, nPixels, nFrames] = ciapkg.io.loadMovieList(movieList, 'passArgs', varargin);

Error in ciatah/modelPreprocessMovieFunction (line 814)
                        thisMovie = loadMovieList(movieList,'convertToDouble',0,'frameList',thisFrameList,'inputDatasetName',options.datasetName,'treatMoviesAsContinuous',options.turboreg.treatMoviesAsContinuousSwitch,'loadSpecificImgClass','single','largeMovieLoad',options.turboreg.largeMovieLoad);

Error in ciatah/modelPreprocessMovie (line 42)
    obj.modelPreprocessMovieFunction('folderListPath',folderListInfo,'fileFilterRegexp',options.fileFilterRegexp,'datasetName',options.datasetName,'frameList',[]);

Error in ciatah/runPipeline (line 209)
                obj.(thisFxn{1});

Error in ciatah/display (line 6)
    obj.runPipeline;
@@@@@@@
+++++++
no movie!
bahanonu commented 1 year ago

Hi, looks like the tiffread dependencies either was not downloaded or the folder is not in the MATLAB path.

Let me know if either of these resolves the issue.

Antorithms commented 1 year ago

Hi, thanks for the super prompt reply. So the function is there and on path.

It's running into some error when reading the file and saying it's not a tiff with this explanation

Error using tiffread (line 168)
This is not a TIFF file (missing 42).

FYI, the tiff file I am using was generated through the inscopix software. I tried to google for this error but I could not find anything straightforward and the past version of ciatah did not have it.

Thanks a lot for your help, Anto

bahanonu commented 1 year ago

Thanks for the update; Inscopix is likely outputting in BigTIFF as opposed to TIFF (the magic number is likely 43 instead of 42 in your file, hence the error you are seeing), especially if your file is >4 GB.

Had encountered this when helping another user recently; I've pushed an update with BigTIFF support (https://github.com/bahanonu/ciatah/pull/119), let me know if that works for you.

Antorithms commented 1 year ago

The update completely solved the issue! thanks a bunch!! Best, Anto