IsoNet-cryoET / IsoNet

Self-supervised learning for isotropic cryoET reconstruction
https://www.nature.com/articles/s41467-022-33957-8
MIT License
67 stars 12 forks source link

Mrc header reading error #46

Closed jake4844 closed 1 year ago

jake4844 commented 1 year ago

Hi, I have a segmentation that I would like use as a mask for isonet. 3dmod can read the file but when I go to extract subtomos I get the following error:######Isonet starts extracting subtomograms###### 04-04 16:43:59, WARNING [isonet.py:295] subtomo directory exists, the current directory will be overwritten04-04 16:43:59, INFO [prepare.py:37] Extract from deconvolved tomogram ./deconv/21aug12a_series0031_8.00Apx.mrc04-04 16:44:02, ERROR [isonet.py:314] Traceback (most recent call last): File "/home/cryoetsoft/IsoNet/bin/isonet.py", line 307, in extract extract_subtomos(d_args) File "/home/cryoetsoft/IsoNet/preprocessing/prepare.py", line 47, in extract_subtomos with mrcfile.open(it.rlnMaskName) as m: File "/home/betsy/.local/lib/python3.10/site-packages/mrcfile/load_functions.py", line 139, in open return NewMrc(name, mode=mode, permissive=permissive, File "/home/betsy/.local/lib/python3.10/site-packages/mrcfile/mrcfile.py", line 115, in init self._read(header_only) File "/home/betsy/.local/lib/python3.10/site-packages/mrcfile/mrcfile.py", line 131, in _read super(MrcFile, self)._read(header_only) File "/home/betsy/.local/lib/python3.10/site-packages/mrcfile/mrcinterpreter.py", line 173, in _read self._read_header() File "/home/betsy/.local/lib/python3.10/site-packages/mrcfile/mrcinterpreter.py", line 211, in _read_header raise ValueError(msg) ValueError: Map ID string not found - not an MRC file, or file is corrupt. I'm guess there is something in the mrc file header that is causing this!! Thanks!

procyontao commented 1 year ago

Hi I think this may related to your filename which contains a dot. You can test whether change file name by removing "8.00A" help.

jake4844 commented 1 year ago

Got it sorted it was a bug in the software used for segmentation in the output file .mrc header:)