Error for NU Refinement with static mask

Hi All, I got this error when running NU Refinement with a static mask using CryoSPARC v2.13.2. Changed the Mask parameter from dynamic to static and other parameters were default. No problem with dynamic mask.

Iteration 3
Using Full Dataset (split 42847 in A, 42847 in B)
Using Max Alignment Radius 24.645 (7.514A)
Start local processing...
Traceback (most recent call last):
  File "cryosparc2_worker/cryosparc2_compute/run.py", line 78, in cryosparc2_compute.run.main
  File "cryosparc2_worker/cryosparc2_compute/jobs/nonuniform_refine/run.py", line 300, in cryosparc2_compute.jobs.nonuniform_refine.run.run_non_uni_refine
AssertionError: Must use dynamic masking in order to apply median filtering on partial volume.

Hi @donghuachen, the workaround for this is:

  • connect your desired mask as input to the mask input of non-uniform refinement
  • do not change the mask type to “static”
  • change the “Dynamic mask start resolution (A)” parameter to something very small like 1.0 A

Now, the job will only use your static mask.

I tried this workaround. However, I got this error during Iteration 3:

– Iteration 3
Using Full Dataset (split 42847 in A, 42847 in B)
Using Max Alignment Radius 25.529 (7.254A)
Start local processing…
Traceback (most recent call last):
File “cryosparc2_worker/cryosparc2_compute/run.py”, line 78, in cryosparc2_compute.run.main
File “cryosparc2_worker/cryosparc2_compute/jobs/nonuniform_refine/run.py”, line 305, in cryosparc2_compute.jobs.nonuniform_refine.run.run_non_uni_refine
UnboundLocalError: local variable ‘color’ referenced before assignment

Hi @donghuachen,
Shoot, you’re right. This workaround will not work. We will fix this properly in the next release, unfortunately there probably isn’t any way to get the job done until then!

@apunjani, Is this static mask issue solved in new version 2.15.0? Thanks.