Import 32-bits .tif from NS microscope

Hello there,

I am having a similar problem to that described in Problems importing tiff files when trying to import micrographs from a Tecnai G2, 200 kV. But obviously in my case there is no gain reference frame:

[CPU: 200.8 MB] Traceback (most recent call last):
File “cryosparc2_master/cryosparc2_compute/”, line 85, in
File “cryosparc2_compute/jobs/imports/”, line 772, in run_import_movies_or_micrographs
imgdata = mrc.read_mrc(os.path.join(proj_dir_abs, exp[‘micrograph_blob/path’]))[1][0]
File “cryosparc2_compute/blobio/”, line 135, in read_mrc
data = read_mrc_data(file_obj, header, start_page, end_page, out)
File “cryosparc2_compute/blobio/”, line 86, in read_mrc_data
dtype = mrc_datatype_to_dtype(datatype)
File “cryosparc2_compute/blobio/”, line 65, in mrc_datatype_to_dtype
assert False,‘Unsupported MRC datatype: {0}’.format(datatype)
AssertionError: Unsupported MRC datatype: 942813506

–> I’ve tried a number of files individually, none works.
–> as I understand - not even sure - the script is trying to find the value for “datatype” in the .tif file, but it can’t. Is there a way to add that information to the .tif file without loosing the information from the image?

(for info I’m using CS 2.15.0)

Hi @carlos, it looks like you’re using the “Import Micrographs” job. This job only supports single-frame .mrc files. Try the “Import Movies” job instead, which should work with .tif files. Let me know if that helps!


Hi Nick,

Well, no, because our NS .tif files are not movies. Cryosparc will tell:
[CPU: 200.8 MB] Traceback (most recent call last):
File “cryosparc2_master/cryosparc2_compute/”, line 85, in
File “cryosparc2_compute/jobs/imports/”, line 611, in run_import_movies_or_micrographs
assert datashape[0] > 1, “Data file %s has only 1 frame - import as micrograph instead” % (abs_path)
AssertionError: Data file /secretproject/2020_09_22_200kV/C6-50k-001.tif has only 1 frame - import as micrograph instead

But thank you for your reply anyways,


Or maybe could I combine the hundreds of .tif files in a few .tiff movies? Any ideas of a program that does that without information loss from the images?

Ah I see the problem now, this definitely looks like a bug in the Import jobs. I’ve recorded this in our internal issue tracker to fix in an upcoming release of cryoSPARC. I’ll try and see if I can find a workaround for you in the mean time.

That would be fantastic, I am eager to test Cryosparc on this.

Hi @carlos, it turned out the fix in cryoSPARC was more complex than we previously thought so unfortunately we cannot put it into the next release.

As a workaround, I suggest converting your .tif files to the .mrc format with the tif2mrc program from the IMOD package. Once you have it installed, you should be able to run it repeatedly from the command line on each .tif file.

tif2mrc C6-50k-001.tif C6-50k-001.mrc
tif2mrc C6-50k-002.tif C6-50k-002.mrc

Once you have that you can import the .mrc files with the “Import Micrographs” job.

Let me know if you run into any trouble with this.


Hello Nick,

Sorry it took me a while, the server was busy with something else.

My installation of IMOD in Debian is not working and I haven’t debugged it yet, but I managed to make tif2mrc run in my MacBook. It doesn’t take that long to convert (obviously I used a for…done loop for 300 files). After that, import went quick and smooth, all micrographs were imported. So thank you very much!

I think people won’t mind to convert as far as we know what to do for that kind of images.

All the best,

1 Like

I have received the same error when i import .mrc file(job: import movies), it is a dose weighted files and we collected from Glacios falcon 4 camera.
error is:
"Data file %s has only 1 frame - import as micrograph instead" % (abs_path)

please let me know if this issue has solved or not and how, thanks a lot!

1 Like