Contrast in Cryo-EM
Where does contrast in an electron micrograph come from? What can we do to produce more contrast? What effects do we have to take into account when processing data from electron micrographs?
Last updated
Where does contrast in an electron micrograph come from? What can we do to produce more contrast? What effects do we have to take into account when processing data from electron micrographs?
Last updated
Contrast is a general term for differences in a signal (typically, an image). For the purpose of this guide, it is sufficient to think of contrast as follows:
Contrast is the difference in intensity (i.e., brightness/darkness) between the darkest object and lightest object in an image
For example, consider this image:
The color bar on the right shows the true value of each pixel — you could think of this value as the electron density, for example. The image above has very good contrast: the darkest region is pure black, and the lightest region is pure white.
This same image with poor contrast might look like this:
Note that the actual values of each square and the background are the same. However, the intensities in the image are closer to each other, which makes the differences in intensity smaller. Contrast is a property of the image, not of the objects. Of course, the process by which we record the image and properties of the objects do have an impact on the image’s contrast. The rest of this page investigates the process of contrast generation in the specific context of cryo-EM.
Cryo-EM micrographs are formed when an electron beam passes through the sample and hits the detector. The detector counts the number of electrons that hit each pixel over the duration of a frame and stores that value as the brightness of that pixel.
If there were no sample, the beam would travel through the microscope and hit the detector. In a well-aligned microscope, this means that each pixel would receive the same number of electrons. There would therefore be a flat grey micrograph, with each pixel only differing by a small amount due to noise and random chance:
If there is a sample between the beam and the detector, the sample will block the electrons. If we assume that no electrons which pass through a sample, we would have near-perfect contrast:
In reality, contrast in cryo-EM is much more complex than this. Electrons almost always pass directly through biological samples without being blocked or absorbed. Furthermore, both the wave and particle nature of electrons in the microscope must be considered in order to understand contrast completely. This guide page covers the mechanisms by which electrons interact with biological samples, and the types of contrast these interactions introduce into the images.
Summary: Amplitude contrast occurs when an object directly reduces the magnitude of the incoming wave.
Perhaps the most obvious type of contrast is amplitude contrast. When a wave (e.g., the electron wave) passes through an object, some amount of that wave will be absorbed, deflected, or otherwise blocked by the object. Thus, the exiting wave has a lower amplitude. Since image intensity is the square of the amplitude of the wave exiting the sample, a change in amplitude results in contrast between the object and its surroundings.
In the animation above, we compare a wave which passes through a sample (top) to a wave which directly hits the detector (bottom). Each wave’s amplitude is marked with a yellow bar on the far right side. This sample has significant amplitude contrast — the wave’s amplitude is reduced by 80% after it exits the sample.
The heavy atoms used for negative stain electron microscopy deflect a large proportion of the incoming electron beam, giving them excellent amplitude contrast. However, amplitude contrast plays a negligible role in cryo-EM of biological samples.
Most biological macromolecules are composed of atoms with similar atomic number to those of the aqueous buffer they’re suspended in. This means that both the “empty” ice and the protein both block electrons with roughly the same strength, so there is little amplitude contrast between the two. A notable exception is nucleic acids, which have heavier phosphorus atoms and so they have a slightly higher amount of amplitude contrast.
The vast majority of contrast in the case of cryo-EM comes, instead, from phase contrast.
Summary: Phase contrast occurs when an object delays or advances the phase of the incoming wave. It is not directly detectable since the amplitude of the wave is unchanged.
Proteins belong to a class of objects called “phase objects”. Instead of absorbing or blocking the incoming wave, phase objects delay the wave, resulting in a phase shift between the incoming wave and the exiting wave.
Although the phrase “phase object” may be unfamiliar, many objects in science or even day-to-day life are phase objects. For instance, glass diffracts light by delaying its phase, and cells have poor contrast in bright-field light microscopy because they are phase objects.
In the above animation, the glass cube is now a pure phase object. Phase objects delay or advance the phase of waves which pass through them. They do not, however, change the amplitude of the incoming wave. Note that at the left hand side, the waves are in sync. However, the top wave is delayed while it travels through the cube. The end result is that when the waves encounter the detector at the right hand side, their amplitude is unchanged, but their phase is shifted by 180°, meaning the peaks line up exactly with the troughs.
Detectors, however, cannot detect phase. They record intensity, which is the square of the wave’s amplitude. When these waves hit the detector, their amplitudes are identical. Thus, normal images of pure phase objects have zero contrast — they are completely invisible!
Given the above, it is natural to ask: how can we produce detectable contrast for a phase object in the microscope? This kind of contrast is called phase contrast, and can be produced by setting up the microscope in a way that causes the incoming wave and delayed wave to interact via interference.
In the above animation, note that the peaks of the top wave align perfectly with the troughs of the bottom wave. When these waves are added together, this will produce a net amplitude of 0. In this way, the phase object has created detectable amplitude contrast in the final image!
Phase contrast is explored in much greater detail in later sections of this page.
Summary: Weak phase objects scatter only a small proportion of the incoming wave. This lets us approximate the (otherwise highly complicated) exit wave as the incoming wave plus a small, scattered wave with a π/2 phase shift. Critically, under this approximation, the amplitude of the scattered wave is linearly proportional to the object's density. In other words, the scattered wave carries an image of the particle.
Real cryo-EM samples produce very small phase shifts in the electron beam, typically on the order of tenths of a degree.
If the vector representation of waves is unfamiliar, it is explained in the Waves as Vectors article.
When viewing a single wave like this, it is easy to imagine directly modeling the phase shifts caused by the sample. However, recall that in the real world a 3D sample is imparting an intricate phase shift on a plane wave:
In the animation above, the plane wave travels from left to right. As it encounters the sample, parts of the wave are delayed as they travel through regions with differing potential (a stationary copy of the plane wave is visible in the top-left to make the phase shifts clear). Remember that these phase shifts are invisible to the detector.
The exact nature of these phase shifts is extremely complicated, depending on a great number of properties of the scattering object and the incoming wave. Perfectly modeling even a single image formed by this process is computationally impractical, and intractable for the hundreds of thousands or even millions of images that need to be modeled during a single 3D map refinement.
Instead of calculating the exit wave explicitly, it is common in cryo-EM to use the weak phase object approximation. In the weak phase object approximation, we assume that the sample only scatters a small proportion of the incoming wave, and that the scattered wave has a constant phase shift of exactly π/2. The exit wave is therefore modeled as the incoming wave plus this small, π/2 shifted wave.
Many derivations of the Weak Phase Object Approximation are available in the literature, typically incorporated into derivations of the CTF. We have included links to several in the References section at the end of this article.
Again, the utility of the Weak Phase Object Approximation is difficult to grasp when considering a single vector. However, again considering a plane wave traveling through a 3D object, its usefulness is apparent:
In this animation, the plane wave again travels left to right. Under the weak phase object approximation, the phase shifts in the incoming wave are modeled as a scattered wave (top) and an unscattered wave (bottom). The scattered wave has a uniform phase shift of π/2, but more importantly, it has an amplitude that is linearly proportional to the scattering potential of the sample. If we could recover an image of the scattered wave alone, we would have an image of the sample.
However, the wave that reaches the detector (the exit wave) is the sum of the scattered and unscattered wave. The scattered wave’s phase shift of π/2 and relatively minuscule amplitude means that the magnitude of the exit wave is unchanged by the scattered wave. Thus, even under the weak phase object approximation, phase objects are still invisible in images!
With the weak phase approximation in place, we can finally discuss the mechanisms that cause signal from the scattered wave to appear in the final image as contrast. There are two primary mechanisms:
Making use of imaging aberrations that produce additional phase shifts of the scattered wave. This is done by intentionally collecting data out of focus.
Introducing additional phase shifts to the scattered wave but not the unscattered wave. This is achieved using a phase plate, which may be simplest to understand for readers who are familiar with optical microscopes.
Summary: Focusing the microscope on a plane some distance away from the sample introduces contrast because scattered waves must travel further than the unscattered wave, causing a phase shift proportional to the scattering angle and distance from the sample.
When the scattered wave is added to the unscattered wave, this phase shift causes a difference in amplitude, which can be detected as an image.
So far in our discussion, the weak phase object approximation indicates that, under standard imaging conditions, images of proteins at focus would have no contrast. What happens if we collect an image at some distance away from focus? To answer this question, we need to consider the fact that the scattered beam changes direction after interacting with the sample.
Note that this scattering occurs in both the +θ and -θ directions, but we only show one of the two beams here for readability. This relationship is called Bragg’s Law and is important in many imaging fields, including x-ray crystallography.
Since the beams are traveling in slightly different directions, they take slightly different amounts of time to reach the same position, which means the phase of the scattered beam shifts relative to the unscattered beam.
In the image above, the pink plane on the left represents the plane of the image. At the sample, the unscattered (yellow) and scattered (blue) waves have traveled the same distance (that is, no distance). Their path length difference is therefore zero, so the difference in their phases is unchanged. The scattered wave has a phase shift of π/2 relative to the scattered wave. Thus, the sum of the two waves (pink) looks identical to the unscattered beam. The sample is invisible at focus.
As the waves travel through space, the scattered wave must travel an additional distance the same vertical position as the unscattered wave — their path lengths are different to reach the same point in space. The further from the sample we measure their phases and the higher the spatial frequency which scattered the beam, the more the path lengths differ.
As we collect an image further and further from focus, the path difference (and therefore phase difference) between the scattered and unscattered beams increases. When the path length differs by a quarter of a wavelength, the scattered beam has a phase shift of π. This means it is destructively interfering with the scattered wave, and the image amplitude is decreased (negative contrast). When the path length differs by three quarters of a wavelength, the opposite happens — the phase of the scattered and unscattered beams are the same, so the image amplitude is increased (positive contrast).
Note that this phase shift depends on both the distance from the sample and θ, which itself depends on the spatial frequency d. We can thus expect the phase of the waves carrying information from the sample to differ based on both
the distance away from the sample at which we image those waves (that is, the defocus), and
the resolution of the information that initially scattered those waves.
To observe this effect, we can plot the contrast at several fixed distances from the sample with varying spatial frequency. In the plot below we plot the contrast between the scattered and unscattered waves at varying distances from focus (indicated on the right in microns). The X axis represents increasing spatial frequency. Contrast is plotted on the Y axis. When a line is at zero, the scattered wave has a phase shift of π/2 or 3π/2, so it does not interfere with the unscattered wave and there is no contrast. When a line is above zero, the scattered and unscattered waves are interfering constructively, generating positive contrast. When a line is below zero, the scattered wave is interfering destructively, generating negative contrast.
Each frequency of information present in the sample scatters a wave at a different angle. We visualize these waves in the X axis, with the lowest frequency waves at the left and the highest frequency waves at the right.
Because they have a different scattering angle, their path length also changes as they travel down the microscope. At 0 µm from the sample, all of the scattered waves are shifted by π/2 compared with the incoming wave, so there’s no contrast. The further they get from focus, the more their path length changes, and so the more their relative phase difference increases. Contrast increases the closer a wave’s phase shift is to an integer multiple of π; we see these maxima and minima in the Y axis. Note that it is not possible to collect an image in which all of the waves have contrast!
Note also that the very lowest frequencies essentially never change from 0 contrast. Their scattering angles are so small that their path length differences are negligible.
Path length difference is the fundamental source of contrast when imaging out of focus: instead of collecting an image focused on the specimen plane, where all spatial frequencies have a phase shift of π/2, we collect an image offset from that plane by some distance. This image has contrast in some spatial frequencies (and not others!) due to path length differences caused by the scattering angle and amount of defocus.
Summary: Spherical Aberration describes the fact that electron microscope lenses overfocus rays that are further from the optical axis. This introduces an additional phase shift to waves scattered by high-frequency features, irrespective of defocus. Spherical Aberration therefore is another mechanism by which the scattered wave becomes visible as contrast in an image.
Although the curves describing the effect of defocus above may look familiar, they are missing a correction for an imperfection in the electromagnetic lens called spherical aberration. Lenses in the electron microscope focus waves more strongly the closer they are to the edge of the lens.
Since higher-frequency features scatter with a greater angle, this adds a difference in focus to waves depending on their scattering angle, which also changes their path length. Spherical aberration generally starts to affect data only at higher resolutions, since it scales with the fourth power of the spatial resolution. We can add a term to reflect this to the function above to model spherical aberration in the sample.
At low defocus, the most obvious effect of considering spherical aberration is the introduction of contrast without any defocus. Since spherical aberration scales with the fourth power of scattering angle, it does not begin to change the path length until higher resolutions, but then oscillates quite rapidly. This is more apparent when considering resolutions up to 1 Å:
It is also possible to produce contrast by passing the scattered beams (but not the unscattered beam) through an environment that induces an additional phase shift (called a “phase plate”), ideally of π/2 or -π/2. The most commonly used phase plates are made of amorphous carbon, but others are under development. Phase plates are currently not often used in single particle analysis.
With the weak phase approximation, defocus, and spherical aberration, we can write down the classic equation for the CTF:
where:
This equation allows us to compute the value of the CTF (a number between -1 and 1, telling us how much contrast is present) at each spatial frequency.
The equation above only models phase shifts and scattering in a single direction. In reality, our images result from plane waves, meaning that the phase shifts and contrast are a function of both X and Y.
A one dimensional equation is no longer sufficient to represent these CTFs — we must consider both scattering direction and angle. Thus, the CTF plots become two-dimensional. You can imagine the 1D CTF graph rotating around the Y axis to generate a 2D surface. The highest points on the surface correspond to the positions with greatest positive contrast, while the lowest points correspond to the greatest negative contrast. These regions are often colored white and black, respectively, creating a 2D image.
In a 2D CTF, each pixel represents a particular wave. The pixel’s angular position denotes the wave’s orientation, while the pixel’s distance from the center of the CTF determines its frequency. Put another way, all pixels in a circle of a given radius represent waves of the same frequency, while all pixels on a line that passes through the center of the image represent waves diffracting in the same direction.
There is no guarantee that these plane waves are perfectly symmetrical. In fact, all cryo-EM images contain some amount of asymmetry due to anisotropic electromagnetic fields in the microscope lenses. This anisotropy is called astigmatism, and results in an under- or over-focused beam depending on scattering direction. This in turn results in an image with different contrast depending on the direction of the scattered wave.
Minor astigmatism is observed in almost every dataset. It is thus important to fit the CTF in two dimensions rather than just the 1D rotational average. All CTF fitting algorithms in CryoSPARC fit astigmatism.
Higher order aberrations can also affect the CTF, but are typically only important at very high resolutions. These aberrations can be corrected using Global CTF Refinement and are discussed in more detail in the CTF Refinement tutorial.
The scattered wave is actually scattered in several directions. Each spatial frequency in the object scatters the electron beam at the angle , where is the electron beam’s wavelength and is the spacing (the spatial resolution) of the object feature in question. For instance, all of the 10 Å information in an object scatters the electron beam at an angle of
is the spatial frequency (e.g., for 5 Å information)
is the electron wavelength
is the defocus (i.e., distance above the sample we focus the image on)
is the spherical aberration constant (a property of the microscope)
is the additional phase shift introduced by a phase plate (if no phase plate is used, )