Skip to main content

Thank you for visiting nature.com. You are using a browser version with limited support for CSS. To obtain the best experience, we recommend you use a more up to date browser (or turn off compatibility mode in Internet Explorer). In the meantime, to ensure continued support, we are displaying the site without styles and JavaScript.

  • Article
  • Published:

Pan-neuronal calcium imaging with cellular resolution in freely swimming zebrafish

Abstract

Calcium imaging with cellular resolution typically requires an animal to be tethered under a microscope, which substantially restricts the range of behaviors that can be studied. To expand the behavioral repertoire amenable to imaging, we have developed a tracking microscope that enables whole-brain calcium imaging with cellular resolution in freely swimming larval zebrafish. This microscope uses infrared imaging to track a target animal in a behavior arena. On the basis of the predicted trajectory of the animal, we applied optimal control theory to a motorized stage system to cancel brain motion in three dimensions. We combined this motion-cancellation system with differential illumination focal filtering, a variant of HiLo microscopy, which enabled us to image the brain of a freely swimming larval zebrafish for more than an hour. This work expands the repertoire of natural behaviors that can be studied with cellular-resolution calcium imaging to potentially include spatial navigation, social behavior, feeding and reward.

This is a preview of subscription content, access via your institution

Access options

Rent or buy this article

Prices vary by article type

from$1.95

to$39.95

Prices may be subject to local taxes which are calculated during checkout

Figure 1: The MPC-based tracking microscope for cellular-resolution calcium imaging in freely swimming larval zebrafish.
Figure 2: Tracking performance.
Figure 3: Algorithm and optical performance of DIFF microscopy.
Figure 4: The registration pipeline and performance.
Figure 5: Cellular-resolution calcium activity in freely swimming elavl3:GCaMP6s and elavl3:Kaede control fish in response to repeated heat pulses.
Figure 6: The tracking microscope enables cellular-resolution calcium imaging during thermal navigation.

Similar content being viewed by others

References

  1. Chen, T.W. et al. Ultrasensitive fluorescent proteins for imaging neuronal activity. Nature 499, 295–300 (2013).

    Article  CAS  Google Scholar 

  2. Ahrens, M.B. et al. Brain-wide neuronal dynamics during motor adaptation in zebrafish. Nature 485, 471–477 (2012).

    Article  CAS  Google Scholar 

  3. Ahrens, M.B., Orger, M.B., Robson, D.N., Li, J.M. & Keller, P.J. Whole-brain functional imaging at cellular resolution using light-sheet microscopy. Nat. Methods 10, 413–420 (2013).

    Article  CAS  Google Scholar 

  4. Panier, T. et al. Fast functional imaging of multiple brain regions in intact zebrafish larvae using selective plane illumination microscopy. Front. Neural Circuits 7, 65 (2013).

    Article  Google Scholar 

  5. Portugues, R., Feierstein, C.E., Engert, F. & Orger, M.B. Whole-brain activity maps reveal stereotyped, distributed networks for visuomotor behavior. Neuron 81, 1328–1343 (2014).

    Article  CAS  Google Scholar 

  6. Koyama, M. et al. A circuit motif in the zebrafish hindbrain for a two alternative behavioral choice to turn left or right. eLife 5, 5 (2016).

    Article  Google Scholar 

  7. Severi, K.E. et al. Neural control and modulation of swimming speed in the larval zebrafish. Neuron 83, 692–707 (2014).

    Article  CAS  Google Scholar 

  8. O'Malley, D.M. et al. Optical physiology and locomotor behaviors of wild-type and nacre zebrafish. Methods Cell Biol. 76, 261–284 (2004).

    Article  Google Scholar 

  9. Venkatachalam, V. et al. Pan-neuronal imaging in roaming Caenorhabditis elegans. Proc. Natl. Acad. Sci. USA 113, E1082–E1088 (2016).

    Article  CAS  Google Scholar 

  10. Nguyen, J.P. et al. Whole-brain calcium imaging with cellular resolution in freely behaving Caenorhabditis elegans. Proc. Natl. Acad. Sci. USA 113, E1074–E1081 (2016).

    Article  CAS  Google Scholar 

  11. Flusberg, B.A. et al. High-speed, miniaturized fluorescence microscopy in freely moving mice. Nat. Methods 5, 935–938 (2008).

    Article  CAS  Google Scholar 

  12. Zong, W. et al. Fast high-resolution miniature two-photon microscopy for brain imaging in freely behaving mice. Nat. Methods 14, 713–719 (2017).

    Article  CAS  Google Scholar 

  13. Scott, B.B., Brody, C.D. & Tank, D.W. Cellular resolution functional imaging in behaving rats using voluntary head restraint. Neuron 80, 371–384 (2013).

    Article  CAS  Google Scholar 

  14. Naumann, E.A., Kampff, A.R., Prober, D.A., Schier, A.F. & Engert, F. Monitoring neural activity with bioluminescence during natural behavior. Nat. Neurosci. 13, 513–520 (2010).

    Article  CAS  Google Scholar 

  15. Fosque, B.F. et al. Neural circuits. Labeling of active neural circuits in vivo with designed calcium integrators. Science 347, 755–760 (2015).

    Article  CAS  Google Scholar 

  16. Dean-Ben, X.L. et al. Functional optoacoustic neuro-tomography for scalable whole-brain monitoring of calcium indicators. Light Sci. Appl. 5, e16201 (2016).

    Article  CAS  Google Scholar 

  17. Berg, H.C. & Brown, D.A. Chemotaxis in Escherichia coli analysed by three-dimensional tracking. Nature 239, 500–504 (1972).

    Article  CAS  Google Scholar 

  18. Ben Arous, J., Tanizawa, Y., Rabinowitch, I., Chatenay, D. & Schafer, W.R. Automated imaging of neuronal activity in freely behaving Caenorhabditis elegans. J. Neurosci. Methods 187, 229–234 (2010).

    Article  Google Scholar 

  19. Leifer, A.M., Fang-Yen, C., Gershow, M., Alkema, M.J. & Samuel, A.D. Optogenetic manipulation of neural activity in freely moving Caenorhabditis elegans. Nat. Methods 8, 147–152 (2011).

    Article  CAS  Google Scholar 

  20. Zheng, M., Cao, P., Yang, J., Xu, X.Z. & Feng, Z. Calcium imaging of multiple neurons in freely behaving C. elegans. J. Neurosci. Methods 206, 78–82 (2012).

    Article  CAS  Google Scholar 

  21. Shipley, F.B., Clark, C.M., Alkema, M.J. & Leifer, A.M. Simultaneous optogenetic manipulation and calcium imaging in freely moving C. elegans. Front. Neural Circuits 8, 28 (2014).

    Article  Google Scholar 

  22. Grover, D., Katsuki, T. & Greenspan, R.J. Flyception: imaging brain activity in freely walking fruit flies. Nat. Methods 13, 569–572 (2016).

    Article  CAS  Google Scholar 

  23. Heckscher, E.S., Lockery, S.R. & Doe, C.Q. Characterization of Drosophila larval crawling at the level of organism, segment, and somatic body wall musculature. J. Neurosci. 32, 12460–12471 (2012).

    Article  CAS  Google Scholar 

  24. Hahm, J.H. et al. C. elegans maximum velocity correlates with healthspan and is maintained in worms with an insulin receptor mutation. Nat. Commun. 6, 8919 (2015).

    Article  CAS  Google Scholar 

  25. Stephens, G.J., Johnson-Kerner, B., Bialek, W. & Ryu, W.S. Dimensionality and dynamics in the behavior of C. elegans. PLoS Comput. Biol. 4, e1000028 (2008).

    Article  Google Scholar 

  26. García, C., Prett, D. & Morari, M. Model predictive control: theory and practice—a survey. Automatica 25, 335–348 (1989).

    Article  Google Scholar 

  27. Mertz, J. Optical sectioning microscopy with planar or structured illumination. Nat. Methods 8, 811–819 (2011).

    Article  CAS  Google Scholar 

  28. Lim, D., Ford, T.N., Chu, K.K. & Mertz, J. Optically sectioned in vivo imaging with speckle illumination HiLo microscopy. J. Biomed. Opt. 16, 016014 (2011).

    Article  Google Scholar 

  29. Mertz, J. & Kim, J. Scanning light-sheet microscopy in the whole mouse brain with HiLo background rejection. J. Biomed. Opt. 15, 016027 (2010).

    Article  Google Scholar 

  30. Lee, S.A., Vallortigara, G., Flore, M., Spelke, E.S. & Sovrano, V.A. Navigation by environmental geometry: the use of zebrafish as a model. J. Exp. Biol. 216, 3693–3699 (2013).

    Article  Google Scholar 

  31. Haesemeyer, M., Robson, D.N., Li, J.M., Schier, A.F. & Engert, F. The structure and timescales of heat perception in larval zebrafish. Cell Syst. 1, 338–348 (2015).

    Article  CAS  Google Scholar 

  32. Gahtan, E., Tanger, P. & Baier, H. Visual prey capture in larval zebrafish is controlled by identified reticulospinal neurons downstream of the tectum. J. Neurosci. 25, 9294–9303 (2005).

    Article  CAS  Google Scholar 

  33. Bianco, I.H., Kampff, A.R. & Engert, F. Prey capture behavior evoked by simple visual stimuli in larval zebrafish. Front. Syst. Neurosci. 5, 101 (2011).

    Article  Google Scholar 

  34. Semmelhack, J.L. et al. A dedicated visual pathway for prey detection in larval zebrafish. eLife 3, 3 (2014).

    Article  Google Scholar 

  35. Dreosti, E., Lopes, G., Kampff, A.R. & Wilson, S.W. Development of social behavior in young zebrafish. Front. Neural Circuits 9, 39 (2015).

    Article  Google Scholar 

  36. Budick, S.A. & O'Malley, D.M. Locomotor repertoire of the larval zebrafish: swimming, turning and prey capture. J. Exp. Biol. 203, 2565–2579 (2000).

    CAS  PubMed  Google Scholar 

  37. Borla, M.A., Palecek, B., Budick, S. & O'Malley, D.M. Prey capture by larval zebrafish: evidence for fine axial motor control. Brain Behav. Evol. 60, 207–229 (2002).

    Article  Google Scholar 

  38. Orger, M.B. & Portugues, R. Correlating whole brain neural activity with behavior in head-fixed larval zebrafish. Methods Mol. Biol. 1451, 307–320 (2016).

    Article  CAS  Google Scholar 

  39. Dunn, T.W. et al. Brain-wide mapping of neural activity controlling zebrafish exploratory locomotion. eLife 5, e12741 (2016).

    Article  Google Scholar 

  40. Bouchard, M.B. et al. Swept confocally-aligned planar excitation (SCAPE) microscopy for high speed volumetric imaging of behaving organisms. Nat. Photonics 9, 113–119 (2015).

    Article  CAS  Google Scholar 

  41. Prevedel, R. et al. Simultaneous whole-animal 3D imaging of neuronal activity using light-field microscopy. Nat. Methods 11, 727–730 (2014).

    Article  CAS  Google Scholar 

  42. Hernandez, O. et al. Three-dimensional spatiotemporal focusing of holographic patterns. Nat. Commun. 7, 11928 (2016).

    Article  CAS  Google Scholar 

  43. Ramdas, A. & Tibshirani, R.J. Fast and flexible ADMM algorithms for trend filtering. J. Comput. Graph. Stat. 25, 839–858 (2014).

    Article  Google Scholar 

  44. Burgess, H.A. & Granato, M. Sensorimotor gating in larval zebrafish. J. Neurosci. 27, 4984–4994 (2007).

    Article  CAS  Google Scholar 

  45. Burgess, H.A. & Granato, M. Modulation of locomotor activity in larval zebrafish during light adaptation. J. Exp. Biol. 210, 2526–2539 (2007).

    Article  Google Scholar 

Download references

Acknowledgements

We thank M. Burns, K. Taute, H. Berg, L. Stern and D. Schaack for feedback on the manuscript. We thank M. Burns and C. Friend for helpful advice and discussions throughout the project. We thank W. Hill for custom electronic circuit design, and C. Stokes for engineering assistance. We thank D.N. Congreve (Rowland Institute at Harvard, Cambridge, Massachusetts, USA) for providing submicrometer fluorescent sheets. We thank H.C. Park (Korea University, Seoul, South Korea) for Tg(elavl3:Kaede) zebrafish. We thank J. Todd for help with software development, and E. Kane for motivating the project. This work was financially supported by the Rowland Institute at Harvard.

Author information

Authors and Affiliations

Authors

Contributions

D.N.R. and J.M.L. conceived and designed the project, instrumentation, and algorithms for DIFF microscopy, MPC-based tracking and image registration; D.H.K. integrated the real-time MPC-based tracking system and DIFF imaging, implemented online and offline image registration, and performed all tracking experiments, with guidance from D.N.R. and J.M.L.; J.K. contributed to the design and implementation of the global shutter imaging system and DIFF microscopy; J.C.M. performed kinematic analyses of fish movement and regression analysis between behavior and neural activity; A.G. and D.G.C.H. generated Tg(elavl3:GCaMP6s)a13203 zebrafish; W.G. contributed to fish genetics and sample preparation; and J.M.L., D.N.R., D.H.K., J.K. and J.C.M. analyzed the data and wrote the manuscript.

Corresponding authors

Correspondence to Jennifer M Li or Drew N Robson.

Ethics declarations

Competing interests

US Patent application 62/487,793 has been filed, with D.N.R., D.K. and J.M.L. named as inventors.

Integrated supplementary information

Supplementary Figure 1 Design and operation of the MPC-based tracking microscope.

(a) 3-D rendering of the tracking microscope. (b) Design of behavior chamber wall with terraced layers of PDMS. The terraced design allows fluorescent light from the brain to reach the imaging objective (NA = 1.0) without obstruction. (c) A custom Model Predictive Control (MPC) implementation is used to keep the brain within the field of view of the DIFF microscope while the animal moves freely in the behavior arena. (d) Schematic of axial motion cancellation. During each piezo Z sweep (black line), each structured fluorescence image is analyzed in real-time to compute an estimate for its axial location (red line) within the targeted brain volume (red shaded region). Near the end of each sweep, the estimated axial brain position is used to adjust the range of the next piezo Z sweep to recenter the brain. (e) Example of closed-loop live Z tracking. As the targeted brain volume shifts axially (red line and shaded region), the piezo Z sweeps are adjusted to center the brain within the next axial sweep.

Supplementary Figure 2 Image-processing pipeline for fish tracking.

Each image undergoes background subtraction and image filtering, followed by feature detection to locate the eyes and yolk. The location and orientation of the brain is determined by the position of the eyes and yolk (Methods). Scale bars, 1 mm. All data were collected from an awake and freely swimming 6 dpf larval zebrafish.

Supplementary Figure 3 Prediction of stage and fish motion optimizes tracking performance.

(a) We model the stage as a linear time invariant (LTI) system that transforms target stage velocity (control input, vinput) to actual stage velocity (voutput). (b) To build a predictive model of stage motion, stage velocities (black) were measured in response to white noise input (red). (c) The impulse response function (red) was solved by ordinary least squares regression, using the preceding 100 ms of control input (vinput) as regressors and the actual stage velocity (voutput) as the response variable. Integrating the impulse response function with respect to time yields the impulse response function for position (red). Every 4 ms, our MPC controller uses this LTI model to select the optimal control input (vinput) that minimizes the predicted future error between the stage position and brain position. (d) The direction of forward fish motion and current forward velocity is estimated from the past 6 time steps of the fish trajectory (-20 ms to 0 ms, red). Based on this history, the fish position is projected 7 time steps into the future (+4 ms to +28 ms, blue). (e) Stage position more closely tracks fish position (black) when fish motion prediction is enabled (blue) than when prediction is disabled (red). (f,g) Cumulative distribution of tracking error with fish motion prediction (blue), without motion prediction (red), or with the actual future fish position (gray). Tracking performance with actual future fish position represents the hypothetical performance of MPC control in the case of perfect motion prediction. (h) Stage position more closely tracks fish position (black) with an MPC controller (blue) relative to a PID controller (red). (i,j) Cumulative distribution of tracking error using MPC (blue) and PID (red) controllers, measured across all time points (i) or while the fish is moving (j). (k) Tracking performance visualized during the replay of a movement bout using MPC or PID control. Scale bar, 500 μm. For cumulative distribution of tracking error, n = 130,621 NIR images (all time) and n = 30,610 NIR images (in motion). All data were collected from an awake and freely swimming 6 dpf larval zebrafish.

Supplementary Figure 4 Joint distribution of tracking error and fish velocity.

Across an imaging session, tracking error is < 100 μm 91.4 % of the time. During motion (Methods), tracking error is < 100 μm 55.1 % of the time, and < 200 μm 78.0 % of the time. n = 7 fish, 3,426,748 images (all time), and 650,653 images (in motion) from awake and freely swimming 5-7 dpf larval zebrafish.

Supplementary Figure 5 Distributions of bout kinematics with and without motion cancellation for two behavioral contexts.

The positions of zebrafish larvae were recorded by a NIR camera during free swimming behavior in either a stationary behavior chamber (blue and black), or in the tracking microscope with motion cancellation enabled and fluorescent excitation light off (magenta and grey) or on (green). Fish were monitored in two behavioral contexts: spontaneous behavior in the absence of paramecia (black and grey) and prey capture in the presence of paramecia (blue, magenta, and green). For each swim bout, twelve kinematic parameters were calculated (Methods). Each panel shows the distribution of one kinematic parameter. n = 11 fish, 19,250 bouts (magenta, prey capture with tracking enabled), n = 2 fish, 2,826 bouts (green prey capture with tracking enabled and fluorescent excitation light on), n = 9 fish, 14,743 bouts (gray, spontaneous swimming with tracking enabled), n = 16 fish, 49,223 bouts (blue, prey capture with stationary chamber), n = 7 fish, 11,109 bouts (black spontaneous swimming with stationary chamber). All data were collected from awake and freely swimming 6-7 dpf larval zebrafish.

Supplementary Figure 6 Motion cancellation and DIFF imaging do not affect prey capture rate.

Larvae were placed in a behavioral chamber containing 20-30 paramecia with tracking ON or OFF, and with the fluorescence excitation light ON or OFF. A box plot of prey capture rate is shown for all three conditions (Methods). Differences between conditions were not statistically significant (p = 0.570 for tracking ON and fluorescence excitation OFF, p = 0. 0.398 for tracking ON and fluorescence excitation ON, Mann-Whitney U test). n = 16 larvae (tracking OFF), n = 7 larvae (tracking ON with fluorescence excitation OFF), and n = 5 larvae (tracking ON with fluorescence excitation ON). Red horizontal line indicates the median, black box spans the first and third quartiles, and whiskers extend to a maximum of 1.5 × IQR beyond the box. Individual data points are shown in gray. All data were collected from awake and freely swimming 6-7 dpf larval zebrafish.

Supplementary Figure 7 Effects of binning and averaging on shot noise and resolution of DIFF optically sectioned images.

Top, optical sections of the brain using 1 × 1 binning. Bottom, optical sections of the brain using 2 × 2 binning. Left to right, images obtained by averaging increasing numbers of frames (1×, 5×, 10×, and 20×). An ROI of the brain is shown below each whole brain section (yellow box, position of the ROI in brain). Scale bar: 50 μm for whole brain sections and 20 μm for ROIs. To avoid activity-related changes in fluorescence, image data was collected from an anaesthetized 5 dpf elavl3:GCaMP6s larval zebrafish.

Supplementary Figure 8 Optical sectioning by DIFF and HiLo.

The raw images required for DIFF and HiLo optical sectioning were collected with the following interleaved sequence: I A (DIFF structured image A and HiLo structured image I s), followed by I u (HiLo unstructured image), followed by I B (DIFF structured image B), repeated across an entire imaging session. All images were collected with the same camera gain (21 dB). To ensure all images had the same average brightness, light source was attenuated by two-fold for I u relative to the structured images (to counteract the two-fold increase in the number of “on” DMD pixels). DIFF optical sectioning was performed using I A and I B. HiLo optical sectioning was performed using I s and I u. Top row, DIFF algorithm applied to I A and I B (Methods and Supplementary Notes). Middle and bottom rows, HiLo algorithm48 applied to I s and I u with shot noise correction enabled (middle) or disabled (bottom). Left column, single optically sectioned images. Middle and left columns, temporally averaged images across 5 timepoints (middle) and 20 timepoints (left). To avoid activity related changes in fluorescence, data shown were collected from an anaesthetized 5 dpf larval zebrafish.

Supplementary Figure 9 Effect of tissue scattering on axial and lateral resolution of DIFF microscopy.

(a) 1 μm fluorescent beads were injected (Methods) into the brain of a 4 dpf nacre−/− fish. The larva was anaesthetized and imaged at 5 dpf. Beads were distributed throughout the fish brain. The outline of the brain is shown in yellow. Top, dorsal view of the brain. Bottom, sagittal view of the brain. Left, images were acquired with high gain to facilitate visualization of the bead locations within the outline of the fish brain. Right, images were acquired with lower gain to accurately measure bead PSFs without saturated pixels. Measured lateral (b) and axial (c) FWHM of 65 beads as a function of each bead’s axial location within the brain.

Supplementary Figure 10 Paired pulse imaging with global shutter sCMOS minimizes motion blur.

(a) The diagram depicts the relative timing of pulsed LED illumination, DMD pattern generation, camera exposure, and camera readout during two paired image acquisition cycles. Each image pair consists of two differentially patterned images. The DMD pattern is switched during the 60 μs interframe interval of the camera. LED pulses are 45 μs each and occur immediately before and after the 60 μs interframe interval. (b) To minimize motion blur, the fluorescence illumination is pulsed for 45 μs per image using a pulse-gated high current drive circuit. (c) Examples of motion blur for fast moving samples. Assuming a residual velocity of 5 mm/s (after motion cancelation), simulated images of the right optic tectum (elavl3::GCaMP6s) are shown assuming pulsed excitation of either 10 ms (left) or 150 μs (right). Scale bar, 50 μm. (d) Spatial shift measured between image pairs acquired with a 45 μs illumination pulse per image with a 60 μs interframe interval between pulse pairs. To minimize motion artifacts, only image pairs with shift < 1 μm are used for analysis of neural activity. n = 57,643 image pairs (all time) and n = 11,112 image pairs (in motion) from an awake and freely swimming 6 dpf larval zebrafish. (e) Photobleaching rate was measured during DIFF imaging in an anaesthetized 6 dpf elavl3:GCaMP6s fish. Imaging was performed at 200 fps, corresponding to 100 paired images and 100 paired LED pulses per second. The red curve was obtained by least squares fitting of a double exponential model: F(t) = Na exp(–t/τa) + Nbexp(–t/τb) where Na = 0.94, τa = 890.4 min, Nb = 0.06, and τb = 3.1 min. To avoid activity-related changes in fluorescence, photobleaching data was collected from an anaesthetized larval zebrafish.

Supplementary Figure 11 Mean fluorescence of an ROI spanning a single neuron measured over 16 heat pulses.

Raw fluorescence traces (F, black) across 16 consecutive heat pulses (pink, 5 s duration, 30 s interval) of a GCaMP6s-expressing neuron (a) and a Kaede-expressing neuron (b). All data were collected from awake and freely swimming 6 dpf larval zebrafish.

Supplementary Figure 12 Neuronal responses to heat pulses in neighboring cells in an elavl3:GCaMP6s fish.

(a) Mean activity (ΔF/F) of an elavl3:GCaMP6s fish (Fig. 4) to heat pulses (5 s duration, 30 s interval). ROI 1 (yellow dot) corresponds to ROI 7 from Fig. 4. ROIs 2-8 (cyan dots) are non-responsive neighboring cells. Scale bars: 100 μm (left) and 20 μm (right). (b) Single trial activity (ΔF/F) of selected neurons in response to individual heat pulses (red lines). (c) Event-triggered average activity (ΔF/F, mean ± s.e.m. are shown in black and gray, n = 18 heat pulses) of the same neurons aligned to the onset of heat (red line). (d) Fish speed (mm/s) across the heat pulses (red lines) from (b). (e) Zoom of the fish speed from (d) across a single trial. (f) Event-triggered average speed (mm/s, mean ± s.e.m. are shown in black and gray, n = 18 heat pulses) of the same fish aligned to the onset of heat (red line).

Supplementary Figure 13 Calcium dynamics of pre-motor and heat-responsive neurons.

Calcium responses to right turns or heat pulses (5 s duration, 30 s interval) are shown for two neurons. Left, event-triggered average activity (ΔF/F, mean ± s.e.m. are shown in black and gray, n = 49 turns) of a hindbrain neuron (top) and habenula neuron (bottom) aligned to right turns (dotted line). Right, event-triggered average activity (ΔF/F, mean ± s.e.m. are shown in black and gray, n = 18 heat pulses) of the same hindbrain neuron (top) and habenula neuron (bottom) aligned to onset of heat (red). Baseline fluorescence (F) is defined as mean fluorescence during a 5 s interval prior to event onset (-10 s to -6 s for activity aligned to turns, -6 s to -1 s for activity aligned to heat onset). All data were collected from an awake and freely swimming 6 dpf elavl3:GCaMP6s larval zebrafish.

Supplementary Figure 14 Regression maps across multiple z planes.

Whole brain activity maps of an elavl3:GCaMP6s larval zebrafish navigating a thermal gradient (same animal as in Fig. 6h,i). Bout angle (a), bout speed (b), absolute temperature (c), and relative temperature (d) were each used as a regressor to generate a regression map showing β, the measured linear relationship between neural activity and the regressor. Each panel shows one Z plane with axial depth within the targeted volume indicated at the bottom of each panel. Scale bar: 100 μm. All data were collected from an awake and freely swimming 6 dpf larval zebrafish.

Supplementary Figure 15 Regression maps of behavior and stimulus parameters.

(a,b) Left, an elavl3:GCaMP6s fish navigating a linear thermal gradient (same animal as in Fig. 6h,i). Colors represent values of bout speed (a) and relative temperature (b) that were used as regressors for ordinary least squares regression analysis of neural activity. Right, whole brain maps of β, the linear relationship between neural activity and each regressor. (c) Whole brain activity maps of an elavl3:GCaMP6s fish (different animal from a,b) responding to heat pulses (5 s duration and 30 s interval). Bout angle was used as a regressor to generate a regression map showing the measured linear relationship between neural activity and bout angle. Each panel shows one Z plane with axial depth within the targeted volume indicated below. All data were collected from awake and freely swimming 6 dpf larval zebrafish.

Supplementary information

Supplementary Text and Figures

Supplementary Figures 1–15 and Supplementary Notes 1–3

Life Sciences Reporting Summary

Supplementary Software

Software for operating the tracking microscope and image registration, as well as license information, implementation, and usage notes.

Brain-wide cellular-resolution imaging of neural activity in a swimming larval zebrafish by DIFF microscopy.

Left, trajectory of an elavl3:GCaMP6s larval zebrafish navigating a linear thermal gradient. During this behavioral epoch, the animal is in exploration mode. Right, DIFF-sectioned images acquired at 2 volumes per second during live tracking. Structured fluorescence image pairs were acquired at 200 Hz and processed by DIFF optical sectioning to obtain DIFF-sectioned images at 100 Hz. A piezo Z stage sweeps the objective axially to record a 100 μm target brain volume with closed loop real-time Z tracking (2 μm axial step per DIFF image, 50 DIFF-sectioned images per sweep, two sweeps per second). Bottom left, the imaging volume (red box) and current sweep location (cyan plane) are shown. For simplicity, the sweep offset applied by real-time live Z tracking is not shown. Dataset was collected from an awake and freely swimming 6 dpf larval zebrafish.

Brain-wide cellular-resolution imaging of neural activity during restricted-area search behavior.

Left, trajectory of an elavl3:GCaMP6s larval zebrafish navigating a linear thermal gradient. During this behavioral epoch, the animal has escaped the hot side of the linear gradient and is displaying restricted-area search behavior to stay localized in the cooler half of the arena. Right, DIFFsectioned images acquired at 2 volumes per second during live tracking. Fluorescence imaging data for this fish was collected with a 100 μm target brain volume generated with a 2 μm axial step per DIFF image, 50 DIFFsectioned images per sweep, and two sweeps per second. Dataset was collected from an awake and freely swimming 6 dpf larval zebrafish.

Registered DIFF-sectioned images from multiple focal planes in the brain of a freely swimming larval zebrafish.

Left, trajectory of an elavl3:GCaMP6s larval zebrafish navigating a linear thermal gradient (same timepoints as Supplementary Video 2). Right, DIFF-sectioned fluorescence images from 8 focal planes of a registered fish brain over the same timepoints as the behavior shown on the left. The raw data was acquired at a volume rate of 2 volumes per second during live tracking and then registered offline through a GPU-accelerated registration pipeline. The registration pipeline consists of an initial 6 Degree of Freedom (6-DoF) rigid registration followed by a piecewise affine registration to accommodate non-rigid deformation. The 8 registered focal planes shown span 84 μm along the dorsal-ventral axis. Fluorescence imaging data for this fish was collected with a 100 μm target brain volume generated with a 2 μm axial step per DIFF image, 50 DIFFsectioned images per sweep, and two sweeps per second. Each pixel is presented without spatial filtering. Single pixel shot noise was reduced for presentation by trend filtering each pixel along the time axis (Methods). Dataset was collected from an awake and freely swimming 6 dpf larval zebrafish.

Registered DIFF-sectioned images in the brain of a freely swimming larval zebrafish, showing fine sectioning and habenula neurons in the ROI.

Left, trajectory of an elavl3:GCaMP6s larval zebrafish navigating a linear thermal gradient (same timepoints as in Supplementary Video 2). Middle, DIFF-sectioned fluorescence images from a single focal plane through the registered fish brain over the same timepoints as the behavior shown on the left. Right, a small ROI volume (256 × 128 × 14 μm) in the habenula of the fish is shown as 8 dorsal (top) to ventral (bottom) sections. Each section represents a single optical section through the habenula with no binning along the axial dimension. Adjacent sections are spaced by 2 μm. Fluorescence imaging data for this fish was collected with a 100 μm target brain volume generated with a 2 μm axial step per DIFF image, 50 DIFFsectioned images per sweep, and two sweeps per second. Bottom left, the targeted imaging volume (red box), selected focal plane (cyan), and habenula volume ROI (yellow box) are shown. Each pixel is presented without spatial filtering. Single pixel shot noise was reduced for presentation by trend filtering each pixel along the time axis (Methods). Dataset was collected from an awake and freely swimming 6 dpf larval zebrafish.

Neuronal activity (ΔF/F) throughout the brain of a freely swimming larval zebrafish.

Left, trajectory of an elavl3:GCaMP6s larval zebrafish navigating a linear thermal gradient (same timepoints as in Supplementary Video 2). Middle, neuronal activity (ΔF/F) throughout a single focal plane of the registered fish brain, shown over the same timepoints as the behavior shown on the left. Right, neuronal activity (ΔF/F) in a small ROI volume (256 × 128 × 14 μm) in the habenula of the fish is shown as 8 dorsal (top) to ventral (bottom) sections. Each section represents a single optical section through the habenula with no binning along the axial dimension. Adjacent sections are spaced by 2 μm. Fluorescence imaging data for this fish was collected with a 100 μm target brain volume generated with a 2 μm axial step per DIFF image, 50 DIFF-sectioned images per sweep, and two sweeps per second. Bottom left, the targeted imaging volume (red box), selected focal plane (cyan), and habenula volume ROI (yellow box) are shown. Shot noise was reduced for presentation by sequentially applying a trend filter to each spatial and temporal dimension (Methods). Dataset was collected from an awake and freely swimming 6 dpf larval zebrafish.

Registration performance evaluated by temporal projection of 4D imaging volume after registration.

Anatomical stack obtained by temporal projection of all registered moving images (across a 10 min imaging session) at a given Z plane within the reference volume. Treating each axial sweep as a single timepoint, we project each moving image into a 4-D dataset (XYZT) sharing the same coordinate system as the reference brain. We present both dorsal and sagittal views of this projection stack to show that subcellular features are resolvable throughout the brain after registration. Dataset was collected from an awake and freely swimming 6 dpf elavl3:GCaMP6s larval zebrafish.

Event-triggered neuronal activity (ΔF/F) aligned to heat onset in freely swimming elavl3:GCaMP6s and elavl3:Kaede fish.

We applied periodic heat pulses (5 s duration, 30 s interval) to freely swimming elavl3:GCaMP6s and elavl3:Kaede larval zebrafish. Fluorescence imaging data for each fish was collected with a 100 μm target brain volume generated with a 2 μm axial step per DIFF image, 50 DIFF-sectioned images per sweep, and two sweeps per second. After DIFF-sectioning and registration, we select a single registered focal plane in the brain. DIFF-sectioned images from this focal plane were then temporally aligned to heat onset (-5 s to +25 s) to obtain an event-triggered time series F(t). Fluorescence images collected at 5 s before heat onset were averaged to obtain a baseline fluorescence image Fbaseline. Neuronal activity is defined as ΔF/F = (F(t) - Fbaseline) / Fbaseline, and overlaid as a heat map (ranging from 0.0 to 0.75) over the grayscale Fbaseline image. The heat pulse is indicated by a red square at the upper left corner of the video. Datasets were collected from an awake and freely swimming 6 dpf elavl3:GCaMP6s larval zebrafish and a 7 dpf awake and freely swimming elavl3:Kaede larval zebrafish.

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Kim, D., Kim, J., Marques, J. et al. Pan-neuronal calcium imaging with cellular resolution in freely swimming zebrafish. Nat Methods 14, 1107–1114 (2017). https://doi.org/10.1038/nmeth.4429

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1038/nmeth.4429

This article is cited by

Search

Quick links

Nature Briefing

Sign up for the Nature Briefing newsletter — what matters in science, free to your inbox daily.

Get the most important science stories of the day, free in your inbox. Sign up for Nature Briefing