Job: Reference Based Auto Select 2D (BETA)
Last updated
Last updated
Select 2D Classes based on their similarity to a 3D reference.
When processing multiple datasets of the same or similar targets, it is often possible to automate large swaths of the processing pipeline due to similar particle size, data quality, etc. Non-interactive 2D class selection can be performed with naive thresholds (choosing classes with high resolution, low ESS, or high particle count) in a Select 2D Classes job. However, this strategy runs the risk of rejecting classes which represent rare or hard-to-align views or including junk classes with artifactually high FRC resolutions.
Reference Based Auto Select 2D selects 2D classes based on their similarity to a user-provided 3D volume. This allows for improved selection of broader sets of 2D classes in an automated workflow, and may help users select classes representing rare views.
We expect this job to be most useful in automated processing pipelines for the same target. When processing data for a target for the first time, the user can determine the appropriate filtering method and threshold values. These can then be re-used in subsequent collections as part of a Workflow to pick appropriate classes and proceed to high resolution reconstruction.
This input is optional. If provided, particles which belong to any class selected by Reference Based Auto Select 2D will also be retained.
These particles should come from the same job as the input 2D class averages.
These class averages will be compared to the reference volume. Classes which meet the user-selected criteria will be selected; the others will be rejected. Note that Reference Based Auto Select 2D compares the class averages to projections from the 3D volume — it does not compare the particle images to the volume at any point.
2D classes are accepted or rejected based on their similarity to projections of this volume. First, the 2D class averages are aligned to the volume in the same way that individual images are aligned to the volume in a 3D refinement. Correlations are then calculated between a projection of the volume along that pose and the 2D class average.
Classes with a resolution worse than (i.e., higher numerical value) this parameter are rejected without comparing them to the reference.
Two correlations are calculated for each 2D class average and its reference projection: the histogram of ordered gradients (HOG) correlation and the Pearson correlation coefficient.
The HOG correlation calculates the similarity in edge position and orientation between the class average and the projection — loosely, the similarity in overall shape. The Pearson correlation coefficient calculates the pixel-by-pixel similarity between the class average and the projection.
Reference Based Auto Select 2D can select 2D classes based on these scores using four distinct modes: cluster, thresholds only, top N classes by correlation score, or top K percentile by correlation score.
First, the 2D class averages are clustered into groups with similar Pearson and HOG correlations. The algorithm checks clusterings using between two and ten clusters, and uses the best-fitting number of clusters. Next, the cluster which has, on average, the highest combined correlation score is selected and all others are rejected.
The user provides thresholds for the Pearson and HOG correlations. Classes for which either correlation is worse than the threshold are rejected. Only classes which have both correlations better than the threshold are selected.
Classes are ordered by the sum of the HOG and Pearson correlations. The first N classes are selected, the remainder are rejected.
If either the HOG or Pearson threshold is greater than 0.0
, classes in these top N will be rejected anyway if their correlation scores are lower than the set threshold(s).
Classes are ordered by the sum of the HOG and Pearson correlations. The top K percentile are selected, the remainder are rejected. For instance, setting this parameter to 66
selects two thirds of the class averages for which the sum of Pearson and HOG correlations are highest.
If either the HOG or Pearson threshold is greater than 0.0
, classes in the top K percentile will be rejected anyway if their correlation scores are lower than the set threshold(s).
If this parameter is on, the reference will be lowpass filtered to the FRC resolution of the 2D class average. This occurs after the volume is aligned to the 2D class averages but before correlation scores are calculated. This is generally expected to improve results, since the input reference may have higher-resolution features not present in the class averages (which are generally lower resolution) which would hurt the correlation scores.
While aligning the volume to the class averages, only frequencies up to this resolution will be considered. In general, setting this parameter to a higher numerical value (i.e., worse resolution) will help prevent overfitting. This may be especially useful when 2D class averages are noisy.
If particles were provided as an input, particles belonging to the selected class averages are output here and otherwise unchanged. This output is not present if particles were not provided.
This output contains the selected class averages.
If particles were provided as an input, particles belonging to the excluded class averages are output here and otherwise unchanged. This output is not present if particles were not provided.
This output contains the rejected class averages.
Examples in this section are from a job run on particles from EMPIAR 10288 (Kumar et al. 2019).
First, 2D class averages which are excluded solely on the basis of their resolution are displayed. The resolution is written out at the top of the class averages.
Next, class averages are plotted by their Pearson and HOG correlations. This plot reflects the Selection mode
chosen by the user:
In cluster
mode, the cluster means are marked with stars.
In thresholds only
mode, the HOG and Pearson thresholds are displayed with blue and red lines, respectively.
In either top N classes by correlation score
or top K percent by correlation score
modes, there are no additional chart elements.
Next, accepted class averages are plotted alongside the projection of the reference volume which aligned to them. The odd images in each row (1st, 3rd, etc.) are 2D class averages, with the Pearson and HOG correlation scores displayed at the top and bottom of the image, respectively. The even images (2nd, 4th, etc.) are projections of the reference volume in the same pose as the 2D class average.
If the 2D class average is high quality and the reference was well aligned, these images should be indistinguishable.
The same plot is produced for the excluded classes:
Note that for noisy classes (for instance, the top-left class of the above image), the reference volume is still displayed in its best-fitting pose. However, this display makes it clear (by eye) that the volume used to calculate correlation is not truly present in the class.
In the plot of rejected 2D class averages, the thresholds are coloured red if they were used to reject a class (for instance, the Pearson correlation coefficient in the top-left class). If multiple good classes are rejected by this job, investigating these classes and determining which threshold caused them to be rejected can help fine-tune the threshold settings.
Reference Based Auto Select 2D is typically run manually once per sample type to determine useful parameter selections for future automated use on similar data.
Once useful threshold settings have been determined, this job can be included in a Workflow, between 2D Classification and Ab Initio Reconstruction jobs. In this way, the workflow can proceed from preprocessing through 3D refinement without any user intervention, extending the degree of automation possible for known samples.
The job can also be useful when attempting to select good classes from a 2D classification that was run with a very large number of classes (e.g. >200). In this case, if there is a coarse resolution reference of the target available, this job can help select matching 2D classes without having to make potentially hundreds of manual selections in a Select 2D Classes interactive job.
Kumar, K. et al. Structure of a Signaling Cannabinoid Receptor 1-G Protein Complex. Cell 176, 448-458.e12 (2019).