hi, error is below:
assert mic_shape == mic.shape, “Micrograph shapes are inconsistent!” # otherwise micrograph_blob/shape is inconsistent with the actual frame shape
AssertionError: Micrograph shapes are inconsistent!
I have tried this on v 4.4.0 and 4.2.1 and same error.
The data are negative stain, which we collected in tif format (jpeg). I had to convert this to no-compression tiff then used tif2mrc. In the end it did result in mrc files which could be imported into cryosparc, picking succeeds, but at the extraction step I received that error for about half the images. The half which worked I can continue processing in 2D classification etc. When I use “header” (imod program) they both seem identical in terms of dimensions and other things.
note that we did not do CTF estimation since, as my understanding is, it is basically pointless for stain data.
any help is appreciated
thanks
Jesse
1 Like
Hi @orangeboomerang, I’d be happy to help with this.
Could you please copy and paste the text of the results of the IMOD header for a successful micrograph and an unsuccessful micrograph?
Also, when you imported these micrographs, did you have the Skip Header Check
slider on or off?
hi @rposert,
we may have sorted out the problem, but I will report back if not. It seems some images collected during data collection had different dimensions. Sometimes there was 1 or 2 extra rows of pixels. No idea how this happened, it is very strange.
thanks
Jesse
1 Like
Hi @rposert and @orangeboomerang,
I’m having the exact same problem under the same circumstances with negative stain data collected on a Hitachi HT7800 with Radius 2.1.
How did you resolve the difference in pixel size between micrographs?
Best,
Gregor
Hi @CurrieLabCSB. If you’re having the same problem with the micrograph shape being different, you should be able to import them separately and proceed with processing as normal. You could accomplish this in a number of ways. I’m most familiar with python, so here’s a short script that should do what you need. Note that you’ll need cryosparc-tools
installed.
from cryosparc import mrc
import shutil
from pathlib import Path
mic_basepath = Path("/path/to/your/micrographs")
micrograph_paths = mic_basepath.glob("*.mrc")
for mic in micrograph_paths:
header, _ = mrc.read(mic)
size_dir = f"{header.nx}x{header.ny}"
try:
shutil.move(mic, mic_basepath / size_dir / mic.name)
except FileNotFoundError:
Path.mkdir(mic_basepath / size_dir)
shutil.move(mic, mic_basepath / size_dir / mic.name)
I also want to note that CryoSPARC only accepts micrographs in .mrc format. If your micrographs are in TIFF format, you’ll need to convert them first.
This happens with the motion corrected stack from EMPIAR 10005 as well. Except CTF estimation worked without issues (4.6.2) but particle extraction freaked out:
Error occurred while processing micrograph J5/imported/017598834880323366821_stack_0394_2x_SumCorr.mrc
Traceback (most recent call last):
File "/home/cryosparcer/bin/cryosparc_worker/cryosparc_compute/jobs/pipeline.py", line 59, in exec
return self.process(item)
File "/home/cryosparcer/bin/cryosparc_worker/cryosparc_compute/jobs/extract/run.py", line 510, in process
result = extraction_gpu.do_extract_particles_single_mic_gpu(mic=mic, bg_bin=bg_bin,
File "/home/cryosparcer/bin/cryosparc_worker/cryosparc_compute/jobs/extract/extraction_gpu.py", line 54, in do_extract_particles_single_mic_gpu
assert mic_shape == mic.shape, "Micrograph shapes are inconsistent!" # otherwise micrograph_blob/shape is inconsistent with the actual frame shape
AssertionError: Micrograph shapes are inconsistent!
Marking J5/imported/017598834880323366821_stack_0394_2x_SumCorr.mrc as incomplete and continuing...
Haven’t checked the raw movies; don’t have time to download 6TB just for a test right now.
edit: Simply splitting the micrographs at Curate Exposures doesn’t work, nor does redoing CTF estimates. They have to be imported independently.