How to incorporate defect file in cryosparc

Is there any way to incorporate defect file (.mrc) in cryosparc while importing movies?

HI @Anshul, please specify the defect file path in the Job Builder for Import Movies:

I tried that already but it is showing some error. I am attaching the screenshot for the same.

Hi @Anshul - the defects file should be a text file, e.g. as generated by DM, not an mrc file.

Can we convert this defect file in mrc format into a text (.txt) file

I don’t know, but I am assuming the mrc file was created from a defects.txt file, as described here ( - perhaps you can obtain it from whoever collected the data?

Hi @olibclarke @spunjani ,
As per your suggestions, I got the defect file in text format and tried to import the movies again but still the job is failing and showing this error. I am attaching the defect file and snapshot of the error.

Hi @olibclarke @spunjani,
this is the error message

Hi @Anshul,

Unfortunately there are several different defect file text formats, and not all of them are supported yet. There is a workaround, however: any pixels that have a value of zero in the gain reference file are treated as defects. So, if you have a defect file in mrc format, verify that it has ones on good pixels and zeros on defective pixels, and then multiply that in to your actual gain reference file.


alternatively, if you have cisTEM handy, just run remove_outlier_pixels on your gain reference - we do this when we have obvious outlier pixels and it does the trick