CTF Estimation
Last updated
Last updated
The Contrast Transfer Function (CTF) models the effect of defocus and microscope aberrations on single particle images. These effects must be corrected before the images can be used to reconstruct a 3D Volume.
This article contains a broad overview of what the contrast transfer function is and where it comes from. Advanced pages provide more detail on waves, contrast, and aliasing. These topics are important both for a deeper theoretical understanding of the technique and also for practical considerations, such as the choice of box size during extraction. Finally, there is a list of useful external resources for interested readers at the end of this page.
Developing even an incomplete understanding of the sources of contrast in cryo-EM is a significant undertaking — we intend this section to serve as a reference over the course of one’s cryo-EM education rather than a prerequisite to performing one’s first CTF job.
When modeling image aberrations, it may be most intuitive to consider the question, “what does the image of a single point look like when imaged by this system”. This concept is known as the Point Spread Function (often abbreviated PSF). In theory, one might expect that an image of a single point would be a simple projection of that point into a 2D image:
However, various imperfections and complications in electron microscopes means this is not the case. The deviations of the true image from this “ideal” projected point are collectively called aberrations. The largest aberration is due to the fact that images are collected out of focus (also known as “with defocus”) to improve contrast (see Contrast in Cryo-EM). The sum total of these aberrations result, generally for cryo-EM, in a point spread function that consists of oscillating bands of dark and light rings around a single point:
To model what would happen for an arbitrary object shape, we could break apart the object into a set of many individual points, and apply the PSF at each point to determine the resulting image.
If the object were split into infinitely many points, applying the point spread function to each point would produce an identical image. This operation is called a convolution, and can be computationally expensive. However, a mathematically useful property of convolution is that it is equivalent to a simple multiplication when working in Fourier space. Thus, to simplify convolution, we can:
take the Fourier transform of our object,
multiply it by the Fourier transform of the point spread function,
and then perform an inverse Fourier transform on the result.
This process produces the image we would expect to see in the microscope.
The Fourier transform of the point spread function is so useful and commonly used that it has its own name: the Contrast Transfer Function (CTF). In addition to its usefulness in convolving the object and the point spread function, the contrast transfer function is also much easier to estimate directly from image data than the point spread function.
The CTF has several practical implications on the processing of cryo-EM data.
Images collected at or near focus will have very little contrast at low resolutions because protein and buffer scatter electrons with approximately the same intensity (see Contrast in Cryo-EM for more details on this topic). This makes them difficult to pick against a noisy background.
For example, consider the simulated images above. The image collected with no defocus is faintly visible without noise, but becomes almost impossible to see with even modest amounts of noise. Compare this to the image simulated with significant (2 µm) defocus. This level of defocus introduces contrast at low frequencies, making the particle clearly visible even when noise is present. However, the image is more obviously corrupted by oscillations in contrast at high frequencies (visible in the simulated image as black and white rings).
Most, but not all, of the image corruption can be modeled and recovered computationally. Thus, micrographs are typically collected with the least defocus for which particle images can still be reliably picked against the noisy background.
As the contrast transfer function oscillates between -1 and 1, it crosses 0 several times. Frequencies for which the contrast transfer function is 0 have no contrast — they are absolutely invisible in the image.
If all images were collected at the same defocus, all of the images would have 0 contrast at the same spatial frequencies. This would result in a specific band of frequencies having little to no contrast, making the map useless. Data is therefore collected over a range of defocus values such that, taken together, each frequency is represented in a sufficient number of particle images to be properly accounted for.
Finally, collecting images with defocus delocalizes signal away from its true position. In the simulated comparison above, note that the high-frequency features (loops in the fabs, helical pitch, etc.) are clearly visible in the left images, where no CTF is applied. Note, of course, that images like this are impossible to collect, since with no defocus, they would not have any contrast. On the right, these same high-frequency features have spread away from their true positions and now overlap, making the image impossible to directly interpret.
This effect is more significant at higher frequencies and at higher defocus values. Particle images which were collected at high defocus and which refine to high resolutions must therefore be extracted with a larger box size to capture information moved away from the particle center.
Cryo-EM samples are never perfectly "flat". Particles tend to concentrate near the air-water interfaces prior to the sample being frozen, and the ice surface itself is often nonplanar. Recalling that defocus affects the contrast transfer function, this means that a single image can contain particles with different defoci and therefore different contrast transfer functions. CryoSPARC provides a patch-based contrast transfer function estimation method in the Patch CTF Estimation job type which examines many different areas in the micrograph to compute a "defocus landscape", to combat this issue. Patch CTF requires no prior information about particle locations within the micrograph, and can be used immediately after motion correction. It can even work on tilted samples without knowing about the tilt beforehand.
It can be difficult to understand the major practical effects of the contrast transfer function in abstract. We therefore present a useful test object here, inspired by examples first presented in Downing and Glaeser (2008).
In the following figures, we mathematically apply the contrast transfer function to a test object. This test object is a wedge with horizontal stripes. The wedge gets narrower, and the stripes closer together, as we move from left to right. In this way, the wedge comprises a smooth range of (vertical) spatial frequencies, starting with the low frequencies at the left and finishing with the high frequencies at the right.
In these simulations, each pixel represents 1 Å. The wedge is therefore approximately 20 nm tall at its tallest side, and contains frequencies corresponding to the resolutions from approximately 26 Å to 6 Å. Additionally, we apply the contrast transfer function only in the vertical direction to prevent information from one spatial frequency spilling into adjacent columns.
At this defocus, the CTF has a negative value for low frequencies. This means that low frequencies (e.g., the left side of the wedge) have negative contrast.
Approximately halfway along the wedge, the CTF crosses zero (dashed vertical lines indicate zero-crossings). The frequencies at and near this point have no contrast — they are the same flat grey as the background. The zero-crossings of the CTF are why it is important to collect data at a range of defocus values. If all of these zero crossings were at the same point, that frequency would never have any contrast, and the images would therefore be incapable of producing a 3D volume.
After the first zero crossing, the CTF has a positive value. This means the wedge is again visible against the grey background, but black has become white and vice versa. This is another effect of the CTF that must be corrected for. In reality, the stripes have the same “density” all the way along the wedge. This flipping is purely an effect of the CTF.
The image above shows the CTF at only a single defocus (-1.5 µm). In the below animation, the defocus varies smoothly from 0.0 to 3.0 µm. The top pane shows the frequency wedge image while the bottom pane shows the CTF. Both are at the same defocus, and the frequencies are aligned in each.
Note first that as defocus increases, so does the contrast at the low frequencies (left end of the wedge). At the beginning of the animation, when the defocus is 0, the left side of the wedge is nearly invisible. As defocus increases, so does the contrast of the low-frequency, left-hand side of the wedge.
Next, observe that the zero crossings move up and down along the wedge as the defocus changes, since the contrast transfer function crosses zero at different frequencies depending on the defocus. Zero crossings are indicated in the bottom pane with dashed lines.
Finally, watch the high-frequency (right-hand) tail of the wedge as defocus changes. The information from this high-frequency region is displaced by a significant fraction of the total size of the object at high defocus!
For an approachable discussion of the contrast transfer function, we recommend Grant Jensen’s lecture on the topic, available on YouTube.
Readers interested in the math behind phase contrast and the contrast transfer function may find the notes from Fred Sigworth and Hemant Tagare interesting. Marin van Heel’s notes also provide interesting discussion of the topic. Finally, Transmission Electron Microscopy by Kohl and Reimer provides a thorough and detailed reference for motivated readers.
To check whether CTF aliasing occurs for a given set of experimental parameters in 2D, consider using this online script, written by Takanori Nakane.
This tool from the Jiang lab simulates a CTF from a variety of user-selected parameters. It can be a helpful way to build intuition about the effects of various microscope parameters on the final CTF.
Another useful tool for developing intuition about the CTF’s effect on images is available from Johannes Elferich.
Downing, K. H. & Glaeser, R. M. Restoration of weak phase-contrast images recorded with a high degree of defocus: The “twin image” problem associated with CTF correction. Ultramicroscopy 108, 921–928 (2008).