Aberration-free multi-plane imaging of neural activity from the mammalian brain using a fast-switching liquid crystal spatial light modulator

: We report a novel two-photon ﬂuorescence microscope based on a fast-switching liquid crystal spatial light modulator and a pair of galvo-resonant scanners for large-scale recording of neural activity from the mammalian brain. The spatial light modulator is used to achieve fast switching between diﬀerent imaging planes in multi-plane imaging and correct for intrinsic optical aberrations associated with this imaging scheme. The utilized imaging technique is capable of monitoring the neural activity from large populations of neurons with known coordinates spread across diﬀerent layers of the neocortex in awake and behaving mice, regardless of the ﬂuorescent labeling strategy. During each imaging session, all visual stimulus driven somatic activity could be recorded in the same behavior state. We observed heterogeneous response to diﬀerent types of visual stimuli from ∼ 3,300 excitatory neurons reaching from layer II/III to V of the striate cortex.


Introduction
Recording neural activity from a large population of neurons in the living brain with physiologically relevant sampling rates and cell-type specificity is particularly important for developing a mechanistic insight into brain function and its disorders [1,2]. The advent of genetically encoded neural activity indicators [3], transgenic reporter mouse lines expressing those indicators in specific cell types [4], and modern fluorescence microscopy, have made optical recording of neural activity a promising approach towards this ambitious goal.
Despite intense efforts and significant advances in imaging neural activity in C. elegans, larval Drosophila, Zebrafish [5][6][7], the large-scale recording of neural activity from the mammalian brain of awake and behaving animals remains a challenge for the following reasons. First, most neural circuits extend over considerable space, requiring a method capable of sampling neural activity in a large volume of brain tissue [8]. Second, mammalian brain tissue is opaque due to its strong scattering profile, making it hard to image neurons deep in the brain [8]. Lastly, suitable imaging methods must overcome motions induced by awake and behaving animals.
The mammalian neocortex is horizontally organized as six morphologically distinct layers, I-VI, with different roles in information processing. Cortical columns, composed of narrow chains of interconnected neurons of different types extending vertically through cortical layers, are perceived as basic modular units of the neocortex [9]. Multi-plane imaging is a conceptually straightforward approach to achieve large-scale recording of neural activity by utilizing the laminar structure of neocortical columns. In particular, more evidence has accumulated over the years showing that locomotion and pupil dilation are accompanied by multiple effects on sensory processing [10]. Changes of behavior state from one imaging session to another make it challenging for experiments designed to understand how object representations are transformed between layers of a cortical column using conventional single-plane two-photon microscopy. Therefore, multi-plane imaging has become essential to record neural activity at different cortical layers in the same behavior state. In addition, when studying the functional connectomics of the neocortex, this approach also facilitates the co-registration of imaging data from the same neocortical column obtained by functional optical imaging and large-scale electron microscopy [11,12], because both methods sample the brain tissue uniformly along spatial dimensions.
Following this strategy, new imaging techniques based on electrically tunable lenses have demonstrated their potential to record neural activity from two different cortical layers [13]. However, the utility of these devices for reliable routine imaging is often limited by their optical performance, including intrinsic aberrations, sensitivity to environmental conditions, slow switching speed, and high manufacturing tolerances. The remote focusing approach moves a low-inertia mirror at the focal plane of a secondary, remote focusing objective and can achieve fast focusing. But it is prone to potential laser damage at the focal spot on the remote focusing mirror, especially when high laser powers are desired for deep imaging [14,15]. Imaging methods based on the concept of temporal focusing [16,17] are typically limited by their penetration depth in the mammalian neocortex. With other advanced optical recording technologies, such as random-access scanning with acousto-optical deflectors [18] or sculpted light microscopy [19], overcoming behavior related motions and neuropil contamination is difficult. Furthermore, sculpted light microscopy also requires custom-designed ultrafast lasers to be fully functional [19].
On the other hand, overdrive techniques recently applied to liquid crystal spatial light modulators (SLM) [20,21], have reduced their switching time to 3 ms [22,23], making them compelling devices for fast-focusing multi-plane imaging. Furthermore, precise phase control of a large number of pixels (i.e., ∼ 250,000 on a single SLM) allows us to generate the high-fidelity wavefront patterns and aberration corrections needed to focus over a wide axial range.
In this work, we report a novel two-photon fluorescence microscope based on an overdrive liquid crystal SLM, resonant-galvo scanners, and a conventional ultrafast laser, capable of recording neocortical activity of thousands of neurons spread across different cortical layers in the brain of an awake and behaving mouse. During each imaging session, we recorded all visual stimulus driven somatic activity in the same behavior state.
Compared to earlier reports concerning the use of SLM for volume imaging [22,24], there are several advances in this work. First, Yang et al [22] used an SLM to split a single laser beam into multiple beamlets while we employ the SLM to rapidly switch between different focal planes. We believe our approach is advantageous in the sense that we don't sacrifice two-photon excitation efficiency by splitting the peak power among focal planes. To maintain the same signal to noise ratio as the one in conventional two-photon microscopy, Yang et al [22] has to increase the applied laser power with the number of beamlets, resulting in a 4∼9 times stronger out-of-focus fluorescence background for all imaging planes when imaging a densely labeled cortical column. Second, the spatial light modulator was not only used to achieve fast switching between different imaging planes in multi-plane imaging but also correct for the intrinsic optical aberrations associated with this imaging scheme. Third, different from previous work [22,24], the resonant galvo scanner scheme we used in this study results in a larger field of view (FOV) (i.e., 500 × 500 µm v.s. 250 × 250 µm) without experiencing much in-plane non-rigid motions for calcium imaging and thus avoids the stitch of multiple small FOVs within a focal plane. Lastly, beyond a proof-of-concept study [24], we applied our imaging method to functional imaging of neural activity from thousands of neurons in the primary visual cortex of awake and behaving mice, revealing an interesting response behavior of certain neurons to various types of visual stimuli. These results demonstrate the utility of our imaging method for meaningful biological studies.

Microscope design and operation
The microscope design is shown in Fig. 1(a). A laser beam from an ultrafast oscillator (Spectra-Physics, Insight X3) with a wavelength of 940 nm and a pulse duration of ∼ 120 fs was expanded by a factor of 6 to fill the active area of the SLM (Meadowlark Optics, HSP-512). The SLM was conjugated to the resonant scanner by a 4f lens system composed of L3 (Edmund Optics, #49-360-INK) and L4 (Edmund Optics, #49-354-INK). The 12 kHz X resonant scanner (Cambridge Technology, CRS 12K) was conjugated to the x galvo scanner (Cambridge Technology, 6215H) by two identical scan lenses L5 and L6 (Thorlabs, SL50-3P) also arranged in a 4f configuration. The x galvo scanner was conjugated to another y galvo scanner (Cambridge Technology, 6215H) with the same pair of scan lenses, i.e., L7 and L8 (Thorlabs, SL50-3P). Similarly, the y galvo was conjugated to the back focal plane of the objective lens (Nikon, N16XLWD-PF) with a 4× Keplerian telescope, containing L9 (Thorlabs, SL50-3P) and L10 (Thorlabs, TL200-3P). The objective was mounted on a piezo actuator (PZT, Physical Instruments, P-725KHDS). The back pupil of the objective was under-filled to achieve an effective excitation numerical aperture (NA) of 0.45. The prechirping configuration for the ultrafast laser pulses was optimized to achieve the highest excitation efficiency. Emitted fluorescence was collected by the same objective as used for excitation and reflected by a dichroic mirror (Semrock, F705-Di01-25x36) towards the active area of a photomultiplier (Hamamatsu, H10770PA-40 SEL).
Our microscope design is based on the modular in vivo multiphoton microscopy system (MIMMS) developed at HHMI Janelia Research Campus [25] but includes significant modifications, as shown in Fig. 1(b). To maintain the strict conjugation between optics in the microscope, we could not move the objective as it is typically used in the MIMMS. Instead, we used a 3D translational stage (Dover, XYR-8080 and ZE-100) to load and unload the animal. The movable microscope head (Sutter Instruments) was rotated along the optical axis of L8 by 23.7 deg and the raised optical breadboard, containing most of the mounted microscope optics, was rotated by another 18 degrees horizontally with respect to the optical table. This geometrical arrangement ensures that during the experiments, the optical axis of the microscope objective is aligned perpendicular to the surface of the cranial window, with a tolerance of less than 1 deg. Eye-tracking and behavior-monitoring cameras were used to track pupil movements and whole body movements of the animal during imaging sessions, respectively. To minimize the perturbation to behavior studies from the resonant scanner noise, the resonant scanner was sealed in an aluminum box. The X galvo in Fig. 1(a) and Fig. 1(b) was not used in this study and kept stationary. Fig. 1(c) shows the detailed experimental setup and how the animal interacts with our microscope during the imaging session.
Due to the strict conjugation between SLM and back focal plane of the objective, any wavefront changes at the SLM are equivalent to a direct manipulation at the Fourier plane of this objective. Therefore, changing the collimation of the laser beam at the back pupil of the objective could be directly controlled by "displaying" defocus wavefront patterns with different magnitudes on the SLM, which were generated using the "gratings and lenses" algorithm typically used in holographic optical tweezers [26][27][28]. As a result, the microscope can focus at different focal planes by applying different defocus wavefront patterns. Before each imaging session, adaptive optics procedures were performed on 2 µm fluorescent beads to correct for residual optical aberrations due to possible slight misalignments and the refractive index mismatch between the Experimental setup for our multi-plane imaging system immersion water and cranial window using a procedure modified from [29], ensuring we are applying ideal defocus wavefront patterns in the system.
A brief description of our adaptive optics procedures is as follows: a series of ANSI standard Zernike patterns were systematically displayed on the SLM and the corresponding two-photon images were recorded. For the Zernike mode with a particular index, the sum of all the pixel values of the images was calculated while the coefficient of the Zernike mode were changed from -1 to 1 with an incremental of 0.2. When the sum of the pixel values was highest, the corresponding coefficient was set as optimum for this particular mode. This procedure was then repeated from the low order Zernike mode to higher ones, up to order 7 (36 terms), with the optimized low-order Zernike patterns as a starting point for the optimization of the higher order Zernike modes. The finally settled Zernike pattern was used as the correction pattern for the aberration. Depending on the parameter settings and complexity of the aberrations to be corrected, it typically takes a few minutes to perform the aberration measurements and one SLM update time (<5 ms) to apply the aberration correction. The aberrations in the optical system is temporally stable. As such, once determined, the adaptive optics correction pattern did not change during the whole imaging session.
Updating the defocus patterns on the SLM was synchronized to a single-frame resonant-galvo scan for image acquisition by a handshake protocol. Single-frame image acquisition based on resonant-galvo scanning was implemented with ScanImage 2016 (Vidrio Technologies), while the SLM was controlled and synchronized with a custom software written in LabVIEW 2015 (National Instruments). After updating the SLM pattern, image acquisition of each frame was hardware-triggered. Upon completing a frame, the falling edge of the frame clock was utilized to trigger the update of the SLM pattern for the next image frame. However, SLM module would not initiate any actions if it did not receive any hardware triggering signal from the resonant-galvo scanning software module and vice versa. By cycling through a limited number of different defocus patterns, the system sequentially and repeatedly acquires images at different depths in the mouse brain.
Compared to [22], our imaging method has to compromise between the frame rate and the number of imaging planes with a given image acquisition time for each plane as shown in Equation. 1 Where I is image acquisition time for each plane, O is overhead switching time, including SLM switching and software overhead, and N is number of imaging planes. For example, for a 12 kHz resonant scanner operated in bidirectional mode and largest possible FOV (i.e., 512 × 512 pixels), the frame rate would be about 6.5 Hz for a total of 6 imaging planes, with 22.4 ms for image acquisition, an average pixel dwell time of 85 ns, and 3 ms for overhead switching.
The frame/volume rate can be increased by reducing the total number of imaging planes or the number of resonant scan lines for each frame.

Surgery
Dexamethasone (3.2 mg/kg, S.C.) was administered to the mouse three hours prior to surgery. Carprofen (5-10 mg/kg, S.C.) was then applied before the incision procedure to remove the skin on top of the head. Under isoflurane anesthesia (5% initially, and 1.5-2 % during the surgery), a custom designed headframe was attached to the skull using Metabond (Parkell) and a 5 mm craniotomy was performed at center coordinates 2.8 mm lateral, 1.3 mm anterior to lambda. The craniotomy was sealed with a stack of three #1 glass coverslips (two 5 mm and one 7 mm glued together) and Vetbond. Metabond cement was further applied to secure the cranial window. The animal's health was monitored for 7 days post-surgery, i.e., overall status (alert and responsive), cranial window clarity, and brain health.

Visual stimulation
Visual stimuli were presented to the right eye of the mouse using an ASUS PA248Q LCD monitor with 1920 × 1200 pixels. The center of the monitor was positioned 15 cm away from the mouse eye, covering a visual space of 120 • × 95 • . The monitor was gamma calibrated using a USB-650 Red Tide Spectrometer (Ocean Optics) and had a mean luminance of 50 cd/m 2 , measured with a SpectroCAL MKII Spectroradiometer (Cambridge Research Systems). All custom visual stimulation scripts were written using PsychoPy [30,31] and Python 2.7. Visual stimuli included drifting gratings, natural movies, and a display of mean luminance grey to record spontaneous activity, with a total length of 62 minutes. The drifting gratings stimulus consisted of a full field drifting sinusoidal grating at a single spatial frequency (0.04 cycles/degree). It was presented to the mouse eye at 8 different directions (separated by 45 degrees) and 5 temporal frequencies (1,2,4,8,15 Hz). Each grating was presented for 2 seconds with 1 second of mean luminance grey between trials. Each grating condition was presented 15 times, in a randomized order, with 30 blank sweep trials interleaved. Natural movie 1 and 2 clips were two different movie clips extracted from the opening scene of the movie Touch of Evil. The length of the natural movie 1 is 2 min, while the natural movie 2 is 30 sec in length. Each movie clip was presented 10 times. A spherical warping was applied to all types of the visual stimuli to compensate for the close viewing angle of the mouse, ensuring size, speed, and spatial frequency were constant across the monitor as seen by the mouse.

Imaging workflow
Each mouse to be imaged on our system first underwent intrinsic signal imaging (ISI) to obtain a retinotopic map to define visual area boundaries and ensure two-photon calcium imaging could be targeted to consistent retinotopic locations. ISI time series were acquired from animals under light anesthesia (1-1.4% isoflurane) to measure the hemodynamic response to the visual stimulus. The isoflurane was administrated using somnosuite (Kent Scientific, model # 715). Sign maps were obtained from the averaged ISI time series from a minimum of 30 sweeps of drifting gratings in each direction. The resulting ISI map was automatically processed, resulting in a segmented and annotated map to guide later two-photon imaging sessions.
After a successful ISI imaging session, each mouse went through a two-week period of habituation to make sure it was habituated to head fixation, visual stimulation, and two-photon imaging.
During two-photon imaging sessions, the mice were positioned on a rotating disk, free to run at will during the experiments. A magnetic shaft encoder (US Digital) attached to this disk recorded the running speed at 60 samples per second. Pupil dilation and the animal posture were monitored and recorded using two separate industrial cameras (Allied Vision, Mako G-032B). Two-photon image acquisition, visual stimulation, eye-tracking, running speed recording, and mouse body monitoring are all synchronized by means of a custom software written in Python 2.7.
More details regarding surgery, imaging procedures, and visual stimulation have been previously reported in [32][33][34]. All experiments and procedures were approved by the Allen Institute Animal Care and Use Committee.

System characterizations
One potential concern with this refocusing method is that it is not operating the objective the way it was designed for (i.e. under the assumption that the rays are entering the entrance pupil in a collimated manner from different angles). Therefore, additional spherical aberrations are unavoidable from the perspective of aberration theory [35]. For this reason, we characterized the performance of our microscope by taking z stack images of 2 µm fluorescent beads using a PZT to move the objective lens while the laser was focused to different focal planes by means of defocus patterns displayed on the SLM. The FWHM of the axial signal profile from those images falls into a range between 7 and 9.25 µm over an axial range of 400 µm when using an effective excitation NA of 0.45, as shown in Fig. 2(a). We observed a slight increase in the average value of the FWHM when we focused towards the edge of this axial range, with a magnitude no more than 1.5 µm. The application of adaptive optics did not improve the performance noticeably, which suggested that the defocus induced aberration is minimum with an effective excitation NA of 0.45. We characterized the z stack images of 2 µm fluorescent beads at different corners of the field of view when the laser beam were focused to different focal planes. We did not observe significant PSF degradation towards the edge of each field of view. The fluctuations of the average FWHM values are less than 1 µm, as shown in Fig. 12.
However, we anticipate a decrease of the acceptable axial range of the point spread function (PSF) degradation when using a higher effective excitation NA. Therefore, to maintain the optical performance of the system over an extended axial range in this scenario, adaptive optics procedures have to be employed to correct for those defocus induced aberrations [36,37]. By replacing lens L3 with one of different focal lengths, the overall beam expansion ratio from the SLM to the back focal plane of the objective can be adjusted to achieve different effective excitation NAs. For each focal plane, an adaptive optics procedure was performed on top of the corresponding defocus pattern displayed on the SLM. The final pattern used for imaging is the sum of the correction pattern and the original defocus pattern. This procedure was repeated through all the imaging planes. The final patterns for each focal plane remained stationary during the following imaging process. As shown in Fig. 2(b), with an effective excitation NA of 0.65 but without adaptive optics, the PSF degraded quickly when the SLM was used to focus tens of microns away from the nominal focal plane. When adaptive optics procedures described before were applied on top of different defocus wavefront patterns, the PSFs at different depths were recovered over an axial range of ∼ 100 µm. Fig. 2 (c) shows the axial signal profile at different focal planes with and without adaptive optics. Even with adaptive optics, we could not fully recover the signal when focusing at +/-46 µm. We used the degradation of the signal down to 64% (corresponding to a Strehl ratio of 0.8 in the context of one photon illumination) of the signal at the nominal focal plane as a cutoff distance for the claimed axial range. By imaging a 100 µm fluorescent grid specimen, Fig. 13 (Appendix 1) shows that there is no noticeable field of curvature or distortion at different focal planes and the fluorescent intensity across the field of view is uniform in general.
We also characterized the relationship between the Zernike defocus term coefficients and the actual axial shifts of the focal plane. We used a well-calibrated stage with encoder (Dover, XYR-8080 and ZE-100) to move the fluorescence bead specimen and used the defocus pattern on the SLM to move the laser focus until we could clearly see images from the beads. We recorded the readings from the encoder and the coefficients of the Zernike defocus term and then fitted those data as a calibration for further fine adjustments. Our measurements show that the locations of actual focal planes obtained with different defocus patterns are almost linearly proportional to the coefficients of the Zernike defocus term. The fit shown in Fig. 2(d) yields y = 0.034x 2 + 17.9753x + 1.7056. This finding agrees well with a previous report on implementing a similar refocusing concept using deformable mirrors for widefield microscopy [38]. We utilized this practically linear dependence to design different multi-plane imaging configurations with focal planes arbitrarily separated within the axial range specified in Fig. 2 (c).

Optical imaging from awake and behaving mice in vivo
We first validated our microscopy system by performing a morphological imaging of the neuronal structures from a living mouse brain (Nr5a1-Cre-Ai14 line). The neurons in this mouse line are genetically labelled with TdTomato. Fig. 3 shows an image stack with 9 planes, from an imaging depth of 193 µm to 241 µm with a separation of 6 µm. 100 image frames were acquired for each plane for a particular defocus pattern on the SLM and then averaged into 1 frame after the motion correction. This was repeated for each focal plane from an imaging depth of 187 µm to 241 µm with a separation of 1 µm. The image stack movie can be found in Visualization 1. Due to space constraints, Fig. 3 only showed 9 of 54 image planes. The images were acquired with the largest possible field of view (i.e., 512×512 pixels, 500 × 500 µm) using a 12 kHz resonant scanner with an average pixel dwell time of 85 ns. This clearly proved that the SLM could be utilized to focus the laser beam at different imaging depth in the living mouse brain without mechanical inertia.
We then demonstrated three different configurations for multi-plane functional imaging using a fast-switching SLM. As shown in Fig. 4(a), we are able to image 6 focal planes spread from layer II/III to layer V with moderate sampling rate (6.5 Hz). Fig. 4 (b) shows another configuration in which two imaging planes were located at two different cortical layers but with a higher sampling rate of 19.5 Hz. By arranging the imaging planes 23 µm separated from each other, we could image a tissue volume of (500 × 500 × 92 µm) at ∼ 7.8 Hz. All the images were acquired with the largest possible field of view (i.e., 512×512 pixels, 500 × 500 µm) using a 12 kHz resonant scanner with an average pixel dwell time of 85 ns.
We imaged neural activity from neurons in layer II to V of an awake and running transgenic mouse (Slc17a7-IRES2-Cre;Camk2a-Tta;Ai94 (TITL-GCaMP6s) line), visiting 6 different focal planes, each plane with a field of view (FOV) of 500 µm × 500 µm (512 × 512 pixels) separated   [10] by 50 µm as shown in Fig. 4(a). The laser powers applied to each plane towards the bottom of the neocortex are 120 mW, 140 mW, 160 mW, 200 mW, 200 mW, and 200 mW, respectively. Each of our imaging session lasted for about 1 hour and we revisited the same cortical column for additional imaging sessions in the following days within a week. We did not observe noticeable laser damages in the following days.
Calcium activity movies were recorded together with synchronized visual stimulus and the recording of running speed as well as pupil dilation. Calcium imaging data for all imaging planes were processed by Suite2P for motion correction, segmentation, and neuropil removal [39]. Figure 5(a) shows the maximum intensity projections of all images after motion correction at imaging depths of 500 µm, 450 µm, 400 µm, 350 µm, 300 µm, and 250 µm, respectively. The frame rate for each plane was about 6.5 Hz. Figure 5(b) shows the ROI segmentation at different imaging depths. Distinct segmentation patterns at different planes clearly demonstrated that those images originated from different depths of the brain. In addition, we observed the number of large cells is gradually increasing, starting from an imaging depth of 400 µm. At an imaging depth of 500 µm, most of the segmented neurons are larger than those segmented in shallow layers, which agrees well with the known anatomy of mouse neocortex. The related calcium imaging movie can be found in Visualization 2. We further quantified both the ∆F/F and signal to noise ratio (SNR) of the calcium imaging movies at different depths, as shown in Fig. 6. We noticed that both the ∆F/F and SNR were relatively constant from the imaging depth of 250 µm to 400 µm. Starting from 450 µm, both ∆F/F and SNR started to drop partly because the applied laser power cannot be further increased compared to the laser powers used in shallow layers, due to the typical maximum laser power limit (200 mW) at the surface of the mouse brain [40]. However, the degraded signal to background ratio did not prevent us from performing further image processing, such as motion correction and segmentation, down to an imaging depth of ∼ 550 µm, as shown in Fig. 14 (Appendix 3). Throughout all 6 imaged focal planes, we are able to extract neural activity from a total of ∼3,300 cells at a sampling rate of ∼ 6.5 Hz in a single imaging session.  To characterize visual response properties of neurons in the mouse visual cortex, a combination of stimuli was used, including drifting gratings (30 min) and 2 natural movies, movie 1 (20 min), movie 2 (5 min), and a 5 minute grey screen to record spontaneous activity. Fig. 7(b) shows activity traces from a selected group of neurons defined in Fig. 7(a). The time sequence of the combined visual stimuli is shown in Fig. 7(c), exactly aligned to the neural activity traces in Fig. 7(b). During the one-hour imaging session, neurons 5 and 6 responded mainly to drifting gratings, while neurons 3 and 4 responded mainly to natural movies. Many neurons behave like neurons 1 and 2, responding to different types of visual stimuli. All this demonstrated a heterogeneous response of neurons in the primary visual cortex to the same visual stimulus and locomotive state. Figure 7(d) presents the recorded running speed, showing the mouse was running during most of the imaging session. We further analyzed the tuning curve of the 4 neurons responding to drifting gratings in Fig. 7(b). Figure 8 shows very similar tuning curves for neurons 5 and 6, while neuron 1 only responded to one direction of drift and neuron 2 was less tuned towards any particular direction. The observation of this heterogeneous response is consistent across different cortical layers. The orientation selectivity index (OSI) for all segmented somata were calculated for each imaging plane. As shown in Fig. 9, we observed many cells with the classical tuning behaviors at different cortical layers. However, a significant portion of excitatory neurons are responding to visual stimuli but don't show a preference towards any particular tuning orientation, which suggests even excitatory neurons in the primary visual cortex may have complicated cortical processing functionality beyond edge detection. The frame rate and number of imaging planes for this imaging scheme can be flexibly configured according to Equation 1. Using the imaging configuration illustrated in Fig. 4(b), Fig. 10 shows maximum intensity projections of the calcium imaging movie at two focal planes located at layers II/III and V of a transgenic mouse (Rorb-IRES2-Cre;Camk2a-tTA;Ai94(TITL-GCaMP6s)), respectively, with a separation of 204 µm and identical frame sizes. Here, frame rates for both planes are about 19.5 Hz. By separating the imaging planes 23 µm from each other, we could also image a volume of (500 × 500 × 92 µm) at ∼ 7.8 Hz. Figure 11 shows maximum intensity projections for images from 5 closely spaced axial planes. One thing worth noting, when imaging planes were arranged close to each other, higher NA (NA=0.65) is used. Adaptive optics can tighten the PSF at different axial focal planes and help to minimize signal crosstalk between planes. However, it seemed hard to completely remove all contaminations simply because of the heterogeneous sizes of neurons.

Discussions
In summary, we have demonstrated aberration-free multi-plane imaging of neural activity using a fast-switching liquid crystal spatial light modulator, capable of recording neocortical activity of thousands of neurons with known coordinates spread across different cortical layers of the brain of awake and behaving mice. During each imaging session, all visual stimulus driven somatic activity could be recorded in the same behavior state. This imaging scheme is readily configurable for volumetric imaging with focal planes arranged close to each other, e.g., 23 µm separation between planes. Similarly, it can also be reconfigured to record neural activity from two cortical layers separated far apart by a few hundred microns, with an improved temporal resolution. In addition, we demonstrated the utility of this method by performing multi-plane imaging across different cortical layers to record heterogeneous response from neurons to different types of visual stimuli. This method does not have special requirements for fluorescence labeling, such as the labeling sparsity [41] or multi-color labeling.
The total number of recorded neurons is limited by the labeling density of the neurons within the sampling volume as well as the sampling rate used in the imaging session. With about 2.5 Hz sampling rate in [39], our imaging scheme could image 16 planes and sample about ∼ 8800 neurons in total. Our current imaging field of view (500 × 500 µm) is limited by the expansion ratio defined by L9 and L10 in Fig. 1. With the improved optical design for L9 and L10, we could further increase the field of view for each imaging plane and thus enable us to record more neurons from each imaging session. Different from [39], our imaging planes are aligned perfectly along the laminar cortical layers and are not required to be arranged to be close to each other.
The extended PSF due to the relatively low numerical aperture could be beneficial for increasing the number of neurons recorded in each imaging session by utilizing the increasingly sophisticated demixing algorithms [39,42]. It would also be interesting to combine this approach with the multi-foci approach reported in [22] to further improve the overall throughput in sparsely labeled specimen. With the ongoing improvements of fast-switching liquid crystal spatial light modulator in terms of switching speed, fill factor, and pixel density [23], we anticipate the frame rate for multi-plane imaging to be ultimately limited by the raster-scan frame acquisition time. For this reason, replacement of resonant scanners with even faster polygon mirrors [43] will be the next step to further improve the acquisition rate and recording capacity for multi-plane imaging. Furthermore, temporal multiplexing [44] can be combined with our multi-plane imaging approach to boost the imaging throughput. Ultimately, both technical routes will be limited by the fluorescence lifetime of available neural activity indicators. In addition, it is also possible to utilize our multi-plane imaging scheme to dynamically correct for the licking-induced motions during the behavior experiment as shown in [45].
Despite the fast-switching speed and the ability to correct the defocus induced aberrations, the nematic liquid crystal SLM, in the current status, still has a 40 % insertion loss due to the imperfect fill factors for the liquid crystal pixels. This shortcoming can be overcome with a more powerful laser as what we used in this work or continuous improvements of the device. Alternatively, electrically tunable lens and the continuous-surface deformable mirror can have a better light throughput. However, electrically tunable lens itself could not correct for the defocus induced aberrations and still suffer from its sensitivity to environmental conditions and fabrication imperfections. Large-stroke continuous-surface deformable mirror [46] is a viable alternative solution for multi-plane imaging but yet to be demonstrated in the context of two-photon fluorescence microscopy. One caveat with the continuous-surface deformable mirror is that the movements of actuators beneath the mirror surface are coupled with each other, which may impose challenges for the aberration corrections when the deformable mirror is driven close to its extreme shape. In contrast, the individual liquid crystal pixels on the SLM are completely independent from each other and therefore allow maximum flexibility for wavefront engineering.
To further improve the imaging penetration depth in a densely labelled cortical column, three-photon imaging [47][48][49][50] is a natural choice. However, the unusually high peak intensity needed to generate the three-photon effects requires a laser with low repetition rate, typically between 0.4 and 4 MHz. For this reason, it limits three-photon imaging to use galvo-galvo scanning mechanism to make sure there is at least one laser pulse per image pixel and typically operate with single-plane imaging only. Our imaging scheme fully supports three-photon imaging by equipping with a pair of galvo scanners as well as scan and tube lens optimized for those wavelengths [51], as shown in Fig. 1(b). In addition, adaptive optics in our imaging scheme could further help to improve the imaging quality for three-photon imaging. To achieve the near-simultaneous imaging of shallow and deeper cortical layers in a single imaging session, temporal multiplexing between our multi-plane imaging [52] and the three-photon imaging is a promising approach towards that direction [53].
Our imaging scheme is based upon two prior knowledge of the neuroanatomy in the neocortex of a mammalian brain: 1. the neurons are distributed in the brain tissue discretely; 2. the mammalian brain is composed of distinct cortical layers. Both assumptions are valid for imaging neural activity of neurons from the mammalian brain. However, when one would like to image some continuous structures in the brain, such as the microglia cells, this method would be sub-optimum and the imaging methods capable of sampling in a continuous volume [54,55] will be a better option.
Our current imaging scheme is also limited to imaging the head-fixed animals. However, there is no theoretical limitation to have a miniaturized SLM, MEMS scanners, GRIN lens as well as wireless data communication working together, which will eventually lead to a compact implementation of this imaging scheme towards multi-plane imaging of the neural activity from freely moving animals [56].
Even though we only demonstrated the utility of our method in the mouse brain, we expect it to be suitable for imaging the neocortex of non-human primates as well [57]. Besides applications in the field of neuroscience, we would expect the concept presented in this paper could be directly translated to other nonlinear optical imaging modalities, including imaging schemes based on second/third harmonic generation [58][59][60], autofluorescence [58,61], and Raman scattering effects [62][63][64][65], in order to improve their imaging throughput to capture the heterogeneous dynamics of biology.