Initial classification uncertainty factor (ICUF)

As a new CryoSPARC user, I am doing my homework by reading the guide. I cannot wrap my head around the “Initial classification uncertainty factor” (ICUF)

I am struggling to formulate an argument for changing ICUF when optimizing CryoSPARC’s 2D classification. I understand how it influences alignment, but when it comes to the reason for changing it and the expected outcome, I find some of the explanations in the CS’s guide contradictory:

From the guide:
“It can be helpful to increase this parameter when good and bad particles are expected to look very similar…”,
but then:
“The end result is that 2D Classification jobs with a higher ICUF tend to have more classes which look like each other, and more classes that look like the “average” particle, rather than rare objects or junk.”

Let’s imagine a situation in which I say, “It might help to increase the ICUF, because <observation>.”

My question is: what would constitute that observation.

2 Likes

Hi @janbinovsky and welcome to the forum! This is a really insightful question, and it’s exactly how I encourage all users to think about parameters like this – what would I actually see in my data that would make me change this?

As to your question itself, let’s take a look at this figure from the “Common Problems - Too few or too many junk classes” section

At iteration zero, all of these jobs find a class that just so happens to look a bit like our target in a particular viewing direction. In the top row, with an ICUF of 1.0, the next iteration has collected essentially all side view particles into this single class because their initial assignment was “confident”. Compare this to the bottom row with an ICUF of 8.0, where even though the side view particles match this class better than any other, they are forced to blur out among other, less likely classes. This results in a poorer class average during these early iterations, but the ICUF effect is decreased at each iteration, so the classes have similar quality by the end of the job.

When looking at a single class like this, it is hard to see why this distinction matters. But now let’s look at all of the classes, at each iteration, for the same particles with ICUF 1.0 or 8.0:

icuf-1

In the ICUF 1.0 job, most classes have fewer than 10 particles. The rest look like the target, but we see essentially one class per viewing direction. This result wouldn’t be particularly useful for filtering junk, since all particles ended up in a class which looks like our target.

icuf-8

At the other end of the spectrum, the ICUF 8.0 job split particles essentially evenly among the classes, creating a wide range of subtly different views of our particle. However, this result would also not be particularly useful for filtering particles, since there are only one or two junk classes (and these have a small number of particles).

I’m using this example because it’s the same one as in the guide, but you should try this on your sample as well! Run 2D Classification jobs with a range of ICUF values and see how the sample responds! The exact result will depend on how many views of your sample you have, the quantity and type of junk images, how many classes you have, the contrast in the images, etc.

But to answer your original question:

  • If most classes are empty and the “probability of best class” chart jumped to near-1.0 quickly, I would increase the ICUF.
  • If almost all classes looked like my target or the “probability of best class” chart took many iterations to approach 1.0, I might decrease the ICUF.

In my experience it is better to err on the side of an ICUF that is too high rather than too low, but this depends on your sample etc.

Please let me know what questions you still have about ICUF, how to know when you should change it, or anything else!

6 Likes

Unless I have an astonishingly clean dataset (rare, even with EMPIAR data) an ICUF of 5 and 150-200 classes normally yields me approximately 50-100 “good” classes, and the rest different sorts of junk, so that tends to be my default for all 2D class runs. Also 2 final full passes, and enough OEM passes to go over the data at least 1.5x.

3 Likes

Thanks for the comprehensive explanation! So the take-home message is again (as for many other jobs) to look at the progression of the job, not the result. It’s a bit difficult to inspect 200 classes iteration by iteration, but I find it helpful to go over the charts. Looking at my test 2D classifications at IUCF=4, the “effective number of assigned classes” and “Probability of best class” stabilized in 5/20 and 9/20 iterations, respectively, with 73/200 good classes. I will experiment with higher ICUF.

Thanks again!

Thanks for the reply.

Is it worth to go over the data 1.5x with a large amount of particles, say 3 million? That would mean increasing batchsize and/or OEM iterations way above the default…and two final passes would take a lot more time.

Yes, it’s worth it even - or especially - then. How much do you trust your data? If it’s really clean and near-perfect, then having the classification algorithm “see” each particle more than once might not be valuable. But IME giving the classification a chance or two to switch assignments around is worth it.

2 Likes