My intention was to process each Gaussian separately. At that point, I had already upgraded to CryoSPARC v5. When I select “Particles (all classes)” from the 3D Classification job as input and run Subset by Statistic using the statistic “per-particle scale (optimal)”, I obtain the following distribution:
However, when I attempt to perform the same subsetting procedure using the individual particle sets output for each class from the 3D Classification job, I encounter the following error:
Traceback (most recent call last):
File "cli/run.py", line 106, in cli.run.run_job
File "cli/run.py", line 211, in cli.run.run_job_function
File "/localapps/cryosparc/cryosparc_worker/compute/jobs/subset_particles/run.py", line 403, in run
assert min(values) != max(values), "All values are the same number, cannot split"
^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: All values are the same number, cannot split
My questions:
Are the per-particle scales calculated during 3D classification not exported with the particle outputs? I’m asking because the distributions shown in the two screenshots differ substantially.
Do the individual class particle subsets generated by 3D Classification not retain the per-particle scale values?
Are the per-particle scales calculated during 3D classification not exported with the particle outputs? I’m asking because the distributions shown in the two screenshots differ substantially.
Yes you’re right – per-particle scales are not written out by 3D class even if it computes them. Where do these particles come from (i.e., a refinement with/without pps optimization on?)? The histograms may differ because the optimal pps values were computed with respect to another volume that doesn’t match the consensus back-projected in 3D class.
Do the individual class particle subsets generated by 3D Classification not retain the per-particle scale values?
Ah, thank you for reporting this. We do passthrough upstream scales to each class, but only the “(used)” version, not the “(optimal)”. We’ve noted this for a future release. For now, you can workaround this by using Particle Sets Tool to intersect the desired class particles with the upstream particle dataset and use the upstream data output to connect to Subset Particles by Statistic.
These particles come from a Local Refinement run without PPS optimization, and should all have PPS=1. Below is the histogram from that Local Refinement job, the source of particles and reference volume for the 3D Class job:
When I try to subset each 3D class by PPS (either “optimal” or “used”), I encounter the same error I mentioned earlier. Given that the parent Local Refinement reports all PPS values as 1.0, it now makes sense to me.
That brings up a new question: since 3D Classification itself does not output PPS values, and the parent Local Refinement shows PPS = 1 for all particles, where are the PPS values in the second histogram from my original post coming from?
All refinement jobs actually compute an optimal scale (even though they may not use it). I suspect that the “optimal” scales in Local Refinement are not actually all 1s (only the “used” ones) but this is being obscured in the individual class outputs of the downstream 3D class job because of the passthrough bug I mentioned above.
Can you try subsetting directly on the local refinement particle output using the “optimal” scales?
Yup, you’re right! The PPS (optimal) distribution from the Local Refine job matches perfectly the second histogram.
Thanks for the clarification. So basically, all refinements compute optimal scale, they might not use it, but particles inherit it anyway. Then, 3D Class also computes optimal PPS with respect to the consensus volume, and those don’t necessarily match the original PPS values because the volume is not necessarily the same as the one used before. However, 3D Class PPS values are not inherited by the output classes. Is that right?
Yep, all right! The only remaining mystery is why the internal 3D class PPS histogram differs so much from the one in local refinement. These should be very similar. Can you list the inputs/custom params to 3D class?