Motion quantification during multi-photon functional imaging in behaving animals

: Functional imaging in behaving animals is essential to understanding brain function. However, artifacts resulting from animal motion, including locomotion, can severely corrupt functional measurements. To dampen tissue motion, we designed a new optical window with minimal optical aberrations. Using the newly developed high-speed continuous volumetric imaging system based on an optical phase-locked ultrasound lens, we quantified motion of the cerebral cortex and hippocampal surface during two-photon functional imaging in behaving mice. We find that the out-of-plane motion is generally greater than the axial dimension of the point-spread-function during mouse locomotion, which indicates that high-speed continuous volumetric imaging is necessary to minimize motion artifacts.


Introduction
Laser scanning two-photon fluorescence microscopy (TPM) has become the method of choice for in vivo deep tissue imaging since its early development in the 1990s [1]. Currently, TPM is widely employed in neuroscience [2, 3] for both structural imaging of neuron morphology and connectivity, and functional imaging of neural network activity. TPM has major advantages for deep tissue imaging [1-4]. The nonlinear excitation inherently confines the fluorescence excitation volume in three dimension (3D), which eliminates out-of-focus bleaching and allows us to collect both the ballistic and the scattered fluorescence emission to represent the signal at the focus. Consequently, TPM can offer orders-of-magnitude improvement in fluorescence signal usage efficiency compared to conventional methods (such as confocal microscopy and wide-field microscopy) at great imaging depth. Moreover, the near infrared laser used in TPM inherently suffers less absorption and scattering and can penetrate deeply in biological tissue [5]. However, the point-scanning approach that provides the huge depth advantage of TPM suffers from low throughput, on the order of tens of millions of pixels per second in the state-of-the-art implementation. Thus, it is prone to motion-associated artifacts during in vivo imaging [6, 7]. To alleviate motion artifacts during functional imaging, neuroscientists generally employ anesthetized animals [2]. Unfortunately, motion from heartbeat and breathing may still perturb the imaging results [8,9]. Moreover, it is well known that anesthesia has profound effects on neural activity [10]. In behavior-related [11], decision-making [12], or reward-reinforcement [13] studies, awake behaving animals must be used, in which case motion artifacts can be quite severe. To obtain accurate measurements of neural signals, a better engineering approach is needed to minimize motion artifacts.
In common procedures, motion registration is often carried out during post hoc image processing [14,15]. As most of TPM imaging experiments are performed in the transverse (xy) plane, the axial (z) motion remains a problem [7, 12, 16]. For calcium imaging, the meaningful signal is fluorescence variation. Thus, the axial motion (in and out of the focal plane) may lead to image intensity fluctuations and produce artifacts, which becomes more apparent for features of comparable size as the axial full-width-at-half-maximum (FWHM) of the point-spread-function (PSF). The simplest solution to minimize axial motion artifacts is to elongate the PSF in the axial direction, which can be done in several ways, including, for example, adding spherical aberration [17], using Bessel beams [18], and implementing phaseonly wavefront shaping [19]. This approach has two major drawbacks. One is the increased fluorescence background in densely labeled samples. Generally, a large number of neurons are labeled with the calcium indicators to ensure enough sampling. A long focus will inevitably generate more background fluorescence from the dense neuropil and hence contain higher shot-noise. In the shot-noise limited conditions, an N-fold background increase will demand an N 2 -fold fluorescence photons to compensate the loss of detection sensitivity [20]. The other drawback is the reduced two-photon excitation efficiency. The long PSF excitation in general has a low Strehl ratio. To compensate for the reduced excitation efficiency, it is necessary to apply a higher laser power.
A better solution to obtain data that is clean and free of motion artifacts is high speed 3D imaging [ under the optical windows to apply slight pressure to the tissue surface can reduce but not fully eliminate brain motion. It is worth noting that thick glass windows can introduce substantial aberrations which may not be fully corrected by the spherical-aberration correction collars in high-end water-dipping objectives.
The axial motion has been quantified in several reports [7, 11, 12, 16, 33], although none of them were measured by direct high-speed 3D imaging, and large discrepancies exist in the estimates. In the cerebral cortex, it was reported that the average axial motion was on the order of 2 µm for imaging head-restrained mice running on a spherical treadmill [7]. In another report, the axial motion reached ~20 µm in the licking-related behavior studies [12]. In the cerebellar cortex, it was reported that the axial motion was ± 3.4 µm (standard deviation, SD) during mouse locomotion [16]. In the hippocampus, the axial motion was reported as 0.7 ± 0.2 μm (mean ± SD) for mice running on a spherical treadmill [11].
Using the OPLUL based high-speed continuous volumetric imaging system, we performed motion quantification of the cerebral cortex and hippocampal surface during twophoton functional imaging in head-restrained mice running on a linear treadmill. We also designed a new optical window for dampening the tissue motion while introducing minimal optical aberration. Our measurement suggests that the axial motion of the cerebral cortex is generally greater than the axial PSF during mouse locomotion, making high-speed continuous volumetric imaging necessary to minimize motion artifacts during functional imaging in behaving animals.

Sample preparations
All procedures involving mice were approved by the Animal Care and Use Committees of Purdue University and HHMI Janelia Research Campus. We used wild-type female mice with virus-infected fluorescent labeling in neurons for imaging.
In time-lapse calcium imaging, image registration is needed to reduce the motion artifacts. Essentially, we translated the images with respect to a reference which can be the mean calcium signal [34] or another static fluorescence signal [35, 36] of several visually-identified stationary volumes. For the latter case, we labelled neurons sparsely with the mixture of diluted AAV2-1-Syn-Cre and AAV2-1-Flex-Syn-dsRed1.2 viruses, which expressed dsRed (a stable red fluorescence protein) for image registration.
To suppress tissue motion during behaving animal imaging in the cerebral cortexes, we designed a new optical window, as shown in Fig. 1. It was made of a disk and two pieces of donut-shaped glass, all made of No.1.5 glass (0.17 mm thick). The glass disk was at the bottom, gently pressing the brain surface. The glass donuts were for holding the disk down while leaving the center open for the water dipping objective lens. If a thick solid glass was used instead (no void in the middle), it would be problematic for high resolution imaging due to the introduced aberrations [37, 38] and may require adaptive optics for proper aberration correction [5]. We joined all three pieces together with ultraviolet curable optical glue (NOA81, Thorlabs Inc.). We made 3.5 mm diameter circular cranial windows at the target areas (S1: 1.4 mm lateral, 2.8 mm posterior to bregma; V1: 2.5 mm lateral, 0.2 mm anterior to lambda), installed the windows, and glued them to the skulls. For hippocampus imaging, we first aspirated the cortex above the hippocampus (1.7 mm lateral, 2.1 mm caudal to bregma) and implanted the hippocampal windows [Figs. 1(e) and 1(f)] as described in reference [11].
After installing the optical windows, we attached head posts to the skull surfaces using dental acrylic and typically allowed 1-2 weeks for recovery before training the mice to run on a linear treadmill. Once the mice became used to running on the treadmill, we started the motion quantification in behaving animal imaging.

Experimental setup
The continuous volumetric imaging system was based on the integration of the OPLUL and a standard TPM, as described in reference [23]. The laser source was a 80 MHz 935 nm 140 fs Ti:Sapphire oscillator (Chameleon, Coherent Inc.). We sequentially conjugated the OPLUL and the Galvo mirrors to the back focal plane of the objective. We used a Nikon 16 × , 0.8 NA objective (working distance 3 mm), whose FWHMs of PSF were 0.4 µm (transverse) and 2.2 µm (axial) for two-photon excitation at 935 nm. The oscillating defocusing wavefront of the OPLUL generated an axial scanning rate of ~1 MHz. We employed Galvo mirrors for transverse scanning, and achieved a kHz cross-sectional frame rate. We can flexibly adjust the volume rate by changing the frame numbers per volume. During imaging, the head-restrained mice were running on a custom linear treadmill [ Fig. 1(a)]. The mouse locomotion was monitored by an optical encoder mounted on the treadmill.

Data processing
Unlike early reports [7, 11, 12, 16], we directly recorded the tissue motion in 3D using highspeed continuous volumetric imaging, which enabled us both to quantify the motion and to accurately remove motion artifacts. We could register the volume data with an intensity-based image registration program (imregister function, MATLAB). Alternatively, we could quantify the motion based on the maximum intensity projections (MIPs) of the volumetric data, and apply the motion vectors to the imaging volumes. In this case, the motion was calculated by cross-correlation algorithm [39] with only translation considered for simplicity. We quantified the tissue motion during functional imaging of behaving mice, as shown in Fig.  2. A sparse subset of neurons in mouse primary barrel cortex (S1) was labelled with the mixture of diluted AAV2-1-Syn-Cre and AAV2-1-Flex-Syn-GCaMP6f viruses. We performed volumetric imaging at 14 Hz (volume size 77 × 15.4 × 40 µm 3 at ~10-300 µm under the dura) with the mouse running on a linear treadmill at liberty. The imaging of GCaMP6f-expressing dendrites and spines [ Fig. 2(a) and Visualization 1] showed apparent motion (Visualization 2) during mouse locomotion. We registered the volumetric data sets with respect to a manual-chosen volume. The resulting motion vectors are shown in Fig. 2(c).

Quantification of motion in the cerebral cortex during functional imaging of behaving mice
We computed the maximum intensity projection of the registered images along time, and then segmented regions of interest using the Simple Neurite Tracer plugin in ImageJ (NIH). We show the fluorescence dynamics ΔF/F of dendrites and spines resulting from spontaneous neuronal activity in Figs. 2(e) and 2(f). As expected, the motion caused substantial artifacts without proper image registration, making it difficult, if possible, to interpret the calcium signal.
We further quantified motion of S1 cortex, as shown in Fig. 3. We applied air puffs to the mouse whiskers for sensory stimulation. We recorded the images at 14 Hz for the 140 × 42 × 40 µm 3 volume at ~10-300 µm under the dura, and used the static signal from dsRedexpressing neurons for registration. Based on Fig. 3(a), mouse locomotion always introduced brain motion. Moreover, there were also slow drifts when the mouse was at rest, which may result from the tissue deformation after abrupt crashes with coverslip during locomotion. In Figs. 3(b) and 3(c), we quantified motion from imaging a mouse on different days. The outof-plane motion (OPM), or z-motion, was not severe as shown in Fig. 3(b). However, the OPM varied significantly in a later imaging section, as shown in Fig. 3(c). We summarized the motion of 3 mice (34 trials in total) in Fig. 3(d). The motion during running was quantified based on the data windows when the running speed was nonzero. The mean values of the maximum in-plane motion (IPM) and OPM during running were 5.8 ± 1.5 µm and 2.8 ± 1.3 µm, respectively. When the mice were at rest, the mean IPM and OPM were 1.3 ± 0.5 µm and 0.3 ± 0.2 µm, respectively. It suggests that OPM was usually smaller than IPM, which may benefit from our novel optical window design. But when the mice were running, transient OPM can be ~5 µm, much larger than the FWHM of axial PSF. We also quantified motion in the primary visual cortex (V1) when the mice were running on a linear treadmill. A blue light provided visual stimulation, together with air puffs to the whiskers for stimulating the mice to run. The imaging was taken at 14 Hz for typical volume size 168 × 84 × 40 µm 3 at ~10-300 µm under the dura. We show the results of motion quantification in Fig. 4, similar to that in the S1 cortex. Abrupt tissue motion was always correlated with mouse running. In Figs. 4(b) and 4(c), we show the results from consecutive trials with a mouse, which suggests that the tissue motion during running was not always repeatable. As an example, the maximum OPM was 2.7 ± 2.3 (mean ± SD) µm during running for mouse #2 in Fig. 4(d), for which the SD was comparable to the mean value. Our quantification of tissue motion at V1 cortex with 3 mice (34 trials in total) shows that the mean values of the maximum IPM and OPM were 4.6 ± 1.5 µm and 1.9 ± 0.8 µm during mouse running, and the mean IPM and OPM were 1.0 ± 0.1 µm and 0.1 ± 0.2 µm when the mice were at rest.

Quantification of motion at hippocampal surface during functional imaging of behaving mice
Functional imaging of the hippocampus in behaving animals is crucial for understanding its key roles in memory and navigation. However, the hippocampus is typically more than 1 mm below the cortical surface in mice. To expose the hippocampus for optical imaging, we aspirated the cortex tissue above the targeted area and then installed a metal cannula with a coverslip sealing the interior opening [ Fig. 1(e)]. We ensured flush contact between the coverslip and hippocampal surface by pressing the cannula slightly before gluing it to the skull [ Fig. 1(f)].
We imaged the hippocampal CA1 neurons at 14 Hz for typical volume size 420 × 140 × 60 µm 3 at ~80-180 µm under the surface, while mice were spontaneously running on a linear treadmill. In Fig. 5, we show the typical motion quantification results from 3 mice over a total of 17 trials. Compared to the results in cerebral cortex imaging, the OPM during running was dampened significantly. However, the slow drifting of the tissue, both in-plane and out-ofplane, were still taking place. Even though the axial drifts were not so severe in Fig. 5(b), it may still interfere the calcium signals from fine structures such as spines and boutons [15], especially in applications for single spike detections.

Discussion
Compared to the reports of large axial motion [12, 33], our novel design of the optical window beneficially dampened brain motion observed in functional imaging of cerebral cortex in behaving mice. By registering the volumetric data achieved with our high-speed volumetric imaging system, we were able to directly quantify tissue motion, especially OPM, during awake, behaving animal imaging. Considering that the tissue motion was not severe under our volume acquisition rate, image registration based only on translation was sufficient. If necessary, the volume rate can be increased, allowing higher-order distortions in the imaging volume to be registered.
Based on our motion quantification, OPM was generally larger than the FWHM of axial PSF, especially in the cerebral cortex, during mouse locomotion. For accurate measurement of fine dendritic structures, the acceptable motion needs to be much less than the FWHM of PSF. For example, moving from the center of the PSF axially by half of its FWHM will cause 50% signal variation, which has far exceeded the 20% signal variation caused by the single action potential triggered calcium transient [21,40,41]. This suggests that high-speed continuous volumetric imaging is necessary to minimize motion artifacts during functional imaging in behaving animals.
Our system can be also employed in motion quantification in functional imaging of neuron activity in the spinal cord [42], where the imaging is more susceptible to motion resulting from mouse respiration and locomotion. In addition to in vivo imaging in behaving mice, our system can be applied in a straightforward way to functional imaging in awake rats [10] and non-human primates [43], where the tissue motion would be more severe.
Considering z-motion in volumetric imaging may result in the loss of information about features of interest at the upper and lower bounders of the imaging volume, online motion correction in real time would be ideal [6,12,42,[44][45][46] to keep the effective size of the imaging volume, even though this is achieved at the cost of system complexity [14].

Conclusions
In summary, we have directly quantified the motion of the cerebral cortex and hippocampal surface during two-photon functional imaging in behaving mice, based on our high-speed continuous volumetric imaging system. Our novel design of the optical window dampened tissue motion effectively while introducing minimal optical aberrations. To minimize motion artifacts, high-speed continuous volumetric imaging is necessary during functional imaging in behaving animals.

Funding
This work is supported by NIH (1U01NS094341-01), Purdue University, and Howard Hughes Medical Institute.