Skip to main content
NIHPA Author Manuscripts logoLink to NIHPA Author Manuscripts
. Author manuscript; available in PMC: 2014 Aug 1.
Published in final edited form as: Nat Protoc. 2013 May 23;8(6):1184–1203. doi: 10.1038/nprot.2013.063

Two-way communication with neural networks in vivo using focused light

Nathan R Wilson 1,*, James Schummers 2,*, Caroline A Runyan 1,3, Sherry Yan 1, Robert F Chen 1, Yuting Deng 1, Mriganka Sur 1
PMCID: PMC4118663  NIHMSID: NIHMS545435  PMID: 23702834

Abstract

Neuronal networks process information in a distributed, spatially heterogeneous fashion that transcends the layout of electrodes. In contrast, directed and steerable light offers the potential to engage specific cells on demand. We present a unified framework for adapting microscopes to use light for simultaneous in vivo stimulation and recording of cells at fine spatiotemporal resolutions. We utilize straightforward optics to lock onto networks in vivo, steer light to activate circuit elements, and simultaneously record from other cells. We then actualize this “free” augmentation on both an “open” two-photon microscope, and a leading commercial one. Following this protocol, setup of the system takes a few days and the result is a non-invasive interface to brain dynamics based on directed light, at a network resolution that was not previously possible and which will further improve with the rapid advance in development of optical reporters and effectors. This protocol is for physiologists who are competent with computers and wish to extend hardware and software to interface more fluidly with neuronal networks.

Keywords: optogenetics, two-photon imaging, optical, neurons, networks

Introduction

Though it has long been appreciated that brain circuits are built from loosely coupled, tightly packed individual elements1, a meaningful way by which to physically interact with them simultaneously has been lacking2. For computers and associated measurement tools to communicate with brain circuits, energy must be distributed across the wide field that the network occupies, yet concentrated at the centers of signal processing and invoked with high spatiotemporal precision. This is true whether for recording (measuring the state of distributed cells or other elements) or for stimulating (biasing the state of those cells).

Stimulating and recording have historically been done using electrodes, owing to the perception that brain circuits are electrical in nature. Very recently, specific breakthroughs in optical recording3-6 and stimulation7-10 have resulted in growing innovation around critical toolsets to at last fulfill the promise of measuring and controlling networks with light, a medium that is spatially and temporally flexible11. Since optical actuators can modulate molecular pathways and channels as well as intracellular voltage, targeted optical energy provides ways to modulate the non-electrical components of cellular and network communication, which could involve more nuanced and numerous interactions than those comprised by intracellular voltage alone12-14.

Here, we present a general methodology for interacting with networks in an “all optical” fashion15-17 in vivo, rapidly steering two penetrating light beams, one for recording and one for stimulating, under automated computer control. This extends a simple framework through which computers communicate bi-directionally across a very small number of channels, but the communication channels are rapidly linked to different cells at a speed that reaches closer to the speed of propagation of action potentials or other network signals. Through this Protocol, we present a complete treatment of the conceptual detail, open source software, and wiring and optics diagrams needed to convert existing microscopes to enable this new format of physiological measurements. These methods can be used in synergy, or piecemeal with other scanning devices that the laboratory wishes to explore.

Specifically, we use fast laser control to show in visual cortex of mice that stimulating multiple or single neuronal subclasses, which express the light-gated cation channel channelrhodopsin-2 (ChR2)18,19, combined with imaging responses of target cells via a fluorescent calcium indicator during visual stimulation, enables the precise delineation of the functional role of the targeted neuronal subclasses. Our treatment includes: 1) an integrated framework for automated cell detection20, image correction, and laser navigation for high-speed optical recording21-23, including the Visor software used in our recent publication24; 2) for the first time since that publication, details on how to optically activate single cells in vivo; 3) coordination of optical stimulation and recording for physiological circuit dissection; and 4) the ability to implement this on custom-made, and crucially for the first time commercial, microscopes.

While our protocol is focused in cortical circuits of mice in vivo, it may prove readily applicable to diverse animal species25 and brain regions26 in vitro and in vivo, and applications may in time only be limited by the (expanding) range of optical reporters and actuators available27-31. We thus provide a physiological framework for taking advantage of a burgeoning field of molecular tools32,33, to bridge the gap from cellular dynamics and structural connectivity34-36 to network physiology.

Comparison with Other Methods

Targeted scanning, or concentrating the laser beam around the areas of interest, is often equated with fast raster scanning due to its typically high temporal resolution. Fast raster scanning indeed has a frame rate that continues to increase and, with bidirectional scanning, can exceed 10 Hz. However, these high frame rates generally come at the cost of a smaller field of view, or reduced pixel resolution. The fundamental issue is that raster scanning, even at a faster rate, will still maintain the same proportion of the time spent in the regions of interest, and therefore faster scan rates result in less sampling time in each cell, decreasing the signal-to-noise ratio. The principal advantage of targeted path scanning therefore, at any speed, is that it focuses signal acquisition at the cell bodies, spending minimal time outside of cells, and this is more a property of the scan path rather than the speed at which the path is traversed. Targeting the laser to computer-defined targets should thus increase both the signal to noise and the effective temporal resolution for a large number of cells.

With the addition of stimulation and recording, laser-based physiology becomes analogous to electrode-based physiology with lingering disadvantages but promising advantages. Electrophysiology relies on a pair of electrodes, one for stimulating and one for recording. Similarly, all-optical relies on a pair of laser beams, which can be focused for either stimulation or recording. In principle, one beam could be used for both at the same time if the wavelengths needed were the same and there was a long duration or spatial coverage needed for activation (so that the imaging beam did not inadvertently activate the imaged cells). In this respect, circuit electrophysiology and optical physiology are similar in that each establishes 1-2 communication channels.

An important difference however, is that circuit electrophysiology is spatially “static”, in that the recording and stimulation elements must be mechanically positioned, a process that is much slower than neurophysiological events and causes damage during motion. In contrast, all-optical is “dynamic”, in that the recording and stimulation elements can be redirected by fast external elements such as mirrors, at a speed that is better matched to neuronal signal propagation and which does not cause damage during transition from one stimulating/recording condition to another (the light is non-damaging, and/or can simply be turned off). Additionally, the area of influence of electrophysiological probes is “local” in that only adjacent or nearby cells can be stimulated or recorded. All-optical, by virtue of its rapid mobility, is “distributed” in that many sites can be sampled at nearly the same time from the perspective of neural dynamics.

That being said, electrophysiology is already applied in a wide variety of neuronal circuits and model organisms, and optical physiology is not. While all-optical network interrogation could in principle be applicable to any cellular system for which changes in state need to be monitored on a fast timescale and can be reported optically, it is yet to be widely applied, and there may be fundamental barriers to doing so in species with limited avenues for genetic manipulation. Nevertheless, advances continue to be made in the linking of optical activators and reporters to different aspects of cell state, their targeting to new cell classes, and their introduction into non-rodent systems.

Electrophysiology also has extremely high signal to noise and temporal resolution, and when skillfully implemented presents a “gold standard” for recording and stimulation that all-optical may never reach. Temporal resolution is particularly important for assessing direct functional connectivity rather than correlations and indirect connectivity. Continuing development of more advanced probes and actuators will partially equalize this disparity.

Finally, another gap between optical physiology and electrophysiology lies in the limited software availability for optical physiology. In working alongside others to help rectify this disparity, our approach supports the open-source model regarding the availability of materials and data that others have also been championing37-41, and which will be crucial to the rapid advancement and standardization of physiological techniques.

Limitations

X-Y Resolution

While two-photon imaging conveys subcellular resolution for imaging and in principle stimulation, our current optical in vivo methods for stimulation utilize visible, one-photon light and thus do not have true cellular resolution (see Supplementary Figures 1 and 2). As a result, optical actuators must be heterogeneously expressed so that cells can be targeted without accidentally hitting neighbors. Using a 2P beam for stimulation with a better actuator will remove this limitation.

Z Resolution

An even more pronounced limitation of using visible, 1P light for stimulation arises in the Z dimension. Here resolution is quite poor (see Supplementary Figure 3), and it is necessary to scan above and below the targeted cell to verify that no other cells are lurking to be activated by the beam as it passes through the tissue. Minimal stimulation can also help mitigate this risk, as out-of-plane activation is reduced, but as with the X-Y resolution, the ultimate solution will come once 2P stimulation can be implemented with better actuators in vivo.

Sensitivity to Motion

It has been hypothesized that targeted scanning may be more sensitive to motion within the animal or of the experimental apparatus. Though the actual measurement could in principle be conducted such that it is no more sensitive to motion than traditional raster scanning, it is possible that the experimenter may be less able to notice motion between trials. To offset this we implement image correction methods that project outlines of the cells from the previous trial over the new cells, so motion is obvious. Future methods might place bright “micro-lanterns” around the field of view that the scan path can use to track deviations and apply real-time voltage corrections to offset the motion.

Mirror Speed / Accuracy

The rate of imaging and the number of simultaneously imaged cells are both constrained by the speed of the mirrors. Acousto-optical deflectors (AODs) that have near-instantaneous spatial sampling may be better equipped for sampling large numbers of cells. Additionally, mirrors are subject to a temporal lag that must be computationally compensated for (as done in this Protocol). Finally, mirrors that turn too fast undergo “ringing” which provides a fundamental limit on network sampling speed. See Supplementary Data 1 and 2 for a treatment of a potential pitfall with mirrors and their remediation.

The speed of the system demonstrated here is sufficient to sample neurons across a circuit in typical fields of view, at a high enough temporal resolution to easily capture calcium responses. However to sample many more neurons without sacrificing signal to noise will require multiple simultaneous beams – faster positioning systems such as AODs in 2D and 3D 7,41-43 should also become more advantageous as high dwell time becomes less crucial through better probes and actuators28,29,44,45.

Signal to Noise

As described in the Comparison with Other Methods section, perhaps the greatest limitation of this new approach is in the amplitude and temporal resolution of the signal. Optical recording and stimulation is a much newer endeavor than electrophysiology, and most of its limitations are the result of a paucity of optical actuators and reporters at this early stage. However, rapid advances in molecular biology, synthetic biology, and chemical engineering are leading to an explosion of new optical reagents available that over time will enable a better signal to noise than is possible by directly measuring electricity, revealing signals in different parts of neurons and circuits, at subcellular resolution and throughout networks.

Experimental Design

Overview

This protocol describes both the necessary adaptations to the microscope and the use of our new system for imaging and stimulation experiments. An overview of how to adapt standard microscopes is presented in Figure 1a-f. The key adaptations involve taking a standard two-photon microscope, adding in a focused blue laser for local activation (~50 um) with its own set of mirrors, and then connecting both sets of mirrors to computer cards and running software for customized control of the laser beams using a specific framework of commands. A schematic of this framework is presented in Figure 1a-f, with a list of specific connections to make provided in Table 1 (see Equipment Setup).

Figure 1. A general template for open, all-optical physiology on custom and commercial microscopes.

Figure 1

Actualizing this format with fully customized control is simple. Modern microscopes have ports to which one can hook up BNCs and take control, using our own more complex experimental signals delivered from custom software. A. A standard current laser setup used in many labs. A two-photon laser is passed through (optionally) a dispersion compensation device, and then through an intensity modulator (e.g. a Pockels cell). The laser is then steered with a pair of X,Y mirrors (galvanometers, “galvos”). Light passes through the microscope, directed by the controlled mirrors, as shown, and exits the objective into the brain tissue. All electrophysiological and imaging interfaces can be driven by a repeatable “open” device architecture involving a breakout box to connect the microscope’s BNC cables, a cable, a computer card, and a standard computer running software like Matlab to define your mirror commands. B. Specific connections for controlling the imaging laser. X and Y commands arise from “analog output” ports, and the imaging signals (red and green) are in turn collected through the “analog input” ports. Three digital signals are also used, to trigger other systems (stimulation laser, electrophysiology, etc), open or close the shutter, and toggle control of the microscope away from the default computer that came with it and towards the custom computer, returning it safely after imaging has completed. C. Figure expansion of the digital signal wiring for clarity. These connections are “plug and play” and require no tools. D. Specific connections for controlling the stimulation laser. Similar to (B) where analog outputs produce X and Y commands. However in this case no inputs are required. The stimulation laser is also triggered by connecting it to the trigger of the other blocks shown in B and E. E. Comparable connections to connect custom electrophysiology, where analog inputs record the signal (voltage in current clamp) and analog outputs control the command current. This system is synchronized with the others via the trigger port. F. An optional electrophysiology amplifier coordinated with targeted imaging.

Table 1.

Summary of connections to fully control a two-laser targeting microscope with custom data.

Computer Data Board Data Port Tvoe Port # Wire Destination Port
1 - Photoactivation 1 - Physiology Ephys Command Analog Output AO0 BNC Ephys Amplifier Command In
(PCI-6229) Stimulation Laser Analog Output AO1 BNC Stimulation Laser Laser Control
Ephys Recording Analog Input AI0 BNC Ephys Amplifier Scaled Output
2 - All-Optical 1 - Optical Recording Mirror Command X Analog Output AO0 BNC Galvo 1 controller X Input
(PCI-6110) Mirror Command Y Analog Output AO1 BNC Galvo 1 controller Y Input
Mirror Feedback X Analog Input AI0 BNC Galvo 1 controller X Feedback
Mirror Feedback Y Analog Input AI1 BNC Galvo 1 controller Y Feedback
Trigger Digital Port Port 0.0 wire Same board PFI0 (wire port)
Digital Output PFI0 BNC All other data cards PFI0 (BNC port)
Shutter Digital Port Port 0.1 wire Same board USER1
Digital Output USER1 BNC Shutter(s) Open/Close
Toggle Galvo Control Digital Port Port 0.2 wire Same Board USER2
Digital Output USER2 BNC Galvo 1 controller Source select
2 - Optical Stimulation Mirror Command X Analog Output AO0 BNC Galvo 2 controller X Input
(PCI-6229) Mirror Command Y Analog Output AO1 BNC Galvo 2 controller Y Input
Mirror Feedback X Analog Input AI0 BNC Galvo 2 controller X Feedback
Mirror Feedback Y Analog Input AI1 BNC Galvo 2 controller Y Feedback
Shutter Digital Output USER2 BNC Shutter 2 Open/Close

This methodology was adapted from hardware and software developed in our lab for the custom control of electrophysiology systems. We then brought together a number of critical advances discovered by others, including: A) the custom control of imaging systems via Matlab37; B) the important insight of using a 1-dimensional “scan path” to switch rapidly between cells of interest instead of doing a raster scan21; C) a high-speed cell detection algorithm for use with the scanning (Sur Laboratory, MIT); D) a straightforward, robust method for deconvolving action potentials to spikes22,46,47; E) the demonstration in tissue slices that ChR2 stimulation could be targeted to specific loci48, which suggested to us that the same could work reasonably well in vivo at shallow depths, or even at any two-photon depth49. Our first attempt at combining those breakthroughs24- the protocol described here and the software provided - are a synthesis of these fundamental advances.

Precautions and planning

While the protocol involves many steps (see Figure 2 for a flowchart overview) and an often beyond-superficial understanding of those steps, once implemented it is very “plug and play” to re-use, and very robust over years of heavy experimental use. The best approach therefore is to systematically execute each step (see Figure 2), and not move forward until the previous step is extremely well understood and stable. It is better to spend an entire day getting one difficult step exactly right, and then enjoy years of its productive use. Most steps are very short and require no biological reagents, and it is recommended to double-check each laser addition using inanimate test preparations (see Procedure) before biological variability and complexity is introduced.

Figure 2. Steps necessary for the reduction of all-optical technology to routine practice in the laboratory.

Figure 2

Many intermediate steps must be systematically rehearsed in isolation along the route to being able to trigger a light with a button and automatically detect responses optically. In the ideal case, these steps can be improved under the support of more reliable methods like electrophysiology or histology, and then brought together. Ultimately, many such steps must all function together simultaneously, including: A) being able to trigger analog stimuli from a computer; B) having this signal result in a time varying light pulse that propagates through a fiber and microscope; C) targeting this light pulse to a small region; D) have the light pulse find a functional effector protein or other actuator within cell(s) of interest; E) have the brain tissue in good condition to respond to the activation and to propagate responses through the network; F) have functioning optical reporters in place to capture those responses; G) have clear and stable imaging conditions to detect the very subtle changes in optical signal that disclose changes in network state; and finally H) have the computer calibrated to receive the corresponding analog signals and decipher them into a clear view of network activity. Bringing together these steps are the subject of the present protocol.

Though the Procedure can in principle be applied to the preparation of the user’s choice, we have utilized it in acute cortical slices in vitro, and in mouse visual cortex in vivo. The detailed descriptions of certain experimental procedures mentioned in this protocol, such as the preparation of mice expressing optical actuators/reporters, cutting brain slices, or performing in vivo craniotomies, are out of the scope of this protocol but are readily available in the literature10,24,48.

Materials

REAGENTS

Mice

Adult mice (>8 weeks) from mouse strains capable of genetic recombination or other methods to enable optical activation may be used with this protocol. For our validations we used heterozygous knock-in driver mice for PV-Cre (Pvalb-Cre, Jackson Labs) or SOM-Cre (SOM-CreERT2, Jackson Labs) backcrossed into a C57BL/6 line. An ideal mouse line for validating the protocol prior to experimental use is the mouse line expressing ChR2-YFP under the Thy1 promoter (Jackson Labs Strain # 007612, B6.Cg-Tg(Thy1-COP4/EYFP)18Gfng/J)9.

Caution Make sure that all animal preparations are carried out under protocols approved by your institution, and in conformance with the relevant regulations and guidelines and ARRIVE principles.

Critical For the purpose of using mice to express optical actuators/reporters, follow the procedures published in10,24 and allow several (4-8) weeks to achieve robust expression.

Craniotomy materials

Materials to enable craniotomy and imaging are extensively described in our earlier work24. All experiments were carried out under protocols approved by MIT’s Animal Care and Use Committee and conforming to NIH guidelines.

Viral transduction materials

Materials to enable viral transduction of optical actuators are extensively described in our earlier work24.

Oregon Green BAPTA-1, AM

Calcium indicator dye for visualizing neuronal responses (Invitrogen, cat. no. O-6807).

EQUIPMENT

Core Components

  • Two-photon microscope – a laser-scanning microscope with two independent sets of galvanometers (Prairie Technologies “In Vivo” microscope, cat. no. “Ultima IV”). The second set of galvanometers is often called an “uncaging” path. Here we will use it for optogenetic activation.

  • Computational software – Matlab (Mathworks, Natick, MA) or equivalent for 2 computers, with Data Acquisition toolbox.

  • Brain circuit interaction software – the Network Visor software (freely available at http://nw.mit.edu/visor) or equivalent, or your own software. Documentation for the use or replication of Visor is presented in Supplementary Note 1.

Components for Basic Photoactivation Setup (with Electrophysiology, Optional) – Steps 1-8

  • Computer # 1 (a standard computer with 2 PCI slots and Windows installed).

  • Data card # 1 (National Instruments, cat. no. PCI-6229).

  • Data cable (National Instruments, cat. no. SHC68-68-EPM).

  • Connector block (National Instruments, cat. no. BNC-2110 for BNC cables).

  • BNC cables – 5 cables to connect your computer to the rig (e.g. AM Systems, cat. no. 726096).

Components for Laser Steering Setup – Steps 9-43

  • Computer # 2 (a standard computer with 2 PCI slots and Windows installed).

  • Data card # 2a (National Instruments, cat. no. PCI-6110 [for imaging]).

  • Data card # 2b (National Instruments, cat. no. PCI-6229 [for stimulation]).

  • Data cables – 2 National Instruments cables, cat. no. SHC68-68-EPM to connect your data cards to the connector blocks.

  • Connector blocks – 2 National Instruments blocks, cat. no. BNC-2110 to plug in your BNC cables.

  • Oscilloscope – 2 basic analog oscilloscopes with a 2-channel concurrent measurement and display (e.g. Tektronix, cat. no. TBS1000).

  • BNC cables – 6 cables to connect your computer to the microscope (e.g. AM Systems, cat. no. 726096).

  • BNC Tees – 3 male-female-male joiner adapters (e.g. AM Systems, cat. no. 726026).

  • Basic 28–16 AWG wires (quantity=10; Mouser Electronics cat. no. 566-9985-100-05) with the insulation stripped on the ends to 0.7 cm.

Components for Targeted Stimulation Optics – Steps 44-72

  • Laser – 200 mW, 473 nm laser with <10% modulation and amplitude control via BNC input (OptoEngine LLC, cat. no. MBL-H-473, plus power supply) for channelrhodopsin stimulation; or a different wavelength for different optical actuators.

  • Fiber – one end SMA format (to connect to laser), other end FC/PC format (depending on microscope port).

  • Coupling Beam Splitter – to allow for simultaneous arbitrary wavelengths for imaging and photostimulation (e.g. Prairie Technologies, cat. no. “C-Glass”).

  • Aperture and focusing lens – to further restrict blue spot, and focus laser upon the mirrors; in conjugate plane with the back of the main microscope objective, as found in the Prairie Technologies “PA” coupling module (cat. no. C-1050). For installing this part, assistance from an expert technician is recommended.

Equipment Setup

Procedure

Configure computer for basic controlled photoactivation ● TIMING 1 d

  1. Practice controlling the laser. Place the laser on a table pointed at a wall. Make sure the laser’s input mode is set to “Computer Control (CC)”. Hook the laser’s input line up to a BNC cable (see “Splicing a BNC cable to 2 loose wires”, if necessary, in Step 7). Connect the other end of the cable to a function generator. Set the generator to create a slowly oscillating step function of 5V and you should see the laser turning on and off. Verify that changing the amplitude and frequency of the function generator changes the intensity and duration of the laser pulses.

    Caution Working with high-powered lasers can be hazardous, and proper safety measures must be taken to protect from damage to eyes and skin. Please consult the safety manuals that come with your lasers and institutional guidelines for their use.

    ?Troubleshooting

  2. Setup a computer to control the laser. In the following steps we will configure a computer for controlling an analog device. We will start with connecting the computer to control the intensity and timing of our photoactivation laser. Notice that similar steps will be repeated below to control our imaging laser mirrors and our stimulation laser mirrors.

  3. Unplug computer # 1 and put data card # 1 inside it. Refer to instructions online for inserting a PCI card into a computer if necessary. Install the software drivers that come with the card.

  4. Connect the data cable to the data card in the rear of the computer.

  5. Attach the connector box to the other end of the cable. You are now ready to interface BNC cables to your computer.

  6. Plug the computer back in, start the computer, and start Matlab. Register your data card with Matlab: go to your Matlab icon and select “Start as Administrator”, and then at the Matlab command line type: daqregister(‘nidaq’).

Connecting computer to photoactivation laser ● TIMING 1 h

  • 7

    Connect your laser to the setup. Connect a BNC cable from the Analog Output port “AO1” to the laser’s computer control leads. If needed, see instructions below for splicing a BNC cable to control leads. Your computer is now interfaced with the laser. Splicing a BNC cable to 2 loose wires: Cut off one end of your BNC cable and peel back its tough rubber exterior. You should find a splayed copper (“ground”) wire wrapped around an inner rubber tube containing another (“signal”) wire. To interface these two wires to your two device leads, match the “ground” to the black lead, and twist the two wires together. Cover in electrical tape. Then, match the “signal” to the red (or otherwise colored) lead. Twist this second pair of wires together and again cover in electrical tape. Wrap the whole set of wires in more tape and reinforce appropriately.

  • 8

    Run the sample code referenced in the software documentation (Supplementary Note 1), “Stimulation > Driving a Photoactivation Laser” and you should see laser pulses being emitted – you can try running the code with different interval, amplitude, pulse frequency and pulse width settings. You can now conduct photoactivation in arbitrary time and intensity patterns, which will be applied later.

    Critical Do not advance until you feel comfortable and practiced using the laser through your computer, and modulating its parameters with the software.

Connecting computer to two-photon imaging microscope ● TIMING 4h

  • 9

    Get oriented. Nearly all two-photon microscopes steer the 2P laser with galvanometers-mounted mirrors that are tilted from side to side using very fast voltage commands. There is usually one mirror that controls the X position of the laser, and a second one slightly later in the lightpath that controls the Y position. These mirrors are connected to a “control box”, which in turn gets inputs from a computer via BNCs. Find this control box, and you should find a place where BNCs can be plugged-in to deliver these control signals, one for the “X” mirror and one for the “Y” mirror. Further helpful instructions for how to do this are available at the ScanImage website (https://openwiki.janelia.org/wiki/display/ephus/ScanImage). To test your custom setup against standard 2P imaging throughout this setup procedure, it is very helpful to have a readily available, easy to maintain stand-in for fluorescently-loaded neurons in the live preparation. Towards this end, an extremely useful substitute is fluorescent beads, which can be suspended in agarose in a petri dish with a bit of water on top, and reused many times (see Box 1). Some 2P microscopes do not use galvanometers, but rather AODs to steer laser position. The electrical control of AODs is outside the scope of this protocol, but several excellent references and now software exist7,41. In this case, a simple software mapping to AOD control logic should permit the rest of the protocol and software described here to function interchangeably. Additionally, this same hardware configuration described in these steps can be used to tap into and control commercial scopes via the ScanImage microscopy package (see Supplementary Note 2).

  • 10

    Tap into the mirror feedback. Here you will learn how to see where your 2P mirrors actually are. This is crucial for knowing the true position of the mirrors during recorded events, which can deviate from the applied command signal due to inertia and other factors (see Supplementary Data 1 and 2). In the control box mentioned in the preceding step, there should be 2 additional BNC ports for “feedback” – one for the X mirror and one for the Y. Run BNCs from each of these into a 2-channel oscilloscope – X into the Channel 1 port and Y into the Channel 2 port. Put the oscilloscope in “XY” display mode. Now run a scan on your microscope – you should see a raster pattern on the oscilloscope screen.

  • 11

    Prepare your computer to control the mirrors. Repeat Step 3 above with Computer # 2 and data card # 2a.

  • 12

    Connect computer to the scanning mirrors. See Table 1 for details. Use BNCs to connect the 2 Analog Input channels (AO0 and AO1) of connector block # 2a to the mirror control box’s X and Y command inputs. It may be possible to preserve the ability to run scans from your normal computer in addition to your new targeted-scanning computer. This requires a “source select” BNC toggle on the mirror control box, which some will have. If this is present, you can get 2 BNC splitters and connect both computers to each, connecting the output of each BNC splitter to the control box’s X command or Y command inputs.

  • 13

    Connect computer to mirror feedback. See Table 1 for details. Use BNCs to connect the 2 Analog Input channels (AI0 and AI1) of data card # 2a to the mirror control box’s X and Y feedback inputs.

  • 14

    Wire board for digital output. To route digital output signals through the BNC ports, you need to connect these ports to the digital output ports (described in Steps 15-17 below) by pressing the basic 28–16 AWG wires into the holes on the board where they will snap into spring-loaded clips and stay in place.

  • 15

    Enable shutter control – get a basic 28–16 AWG wire as in Step 14 with stripped ends, and connect one end to the small hole in the array of holes labeled “Port 0.1”. Press the other end into the small hole labeled “USER1”. This will allow digital signals that the computer produces on Port 0.1 to flow out of the BNC port “USER1”.

  • 16

    Enable toggling control of the mirrors – as in the previous step, press a wire into “Port 0.2”. Press the other end into the small hole labeled “USER2”.

  • 17

    Enable triggering of other boards – as in the previous step, press a wire into “Port 0.0”. Press the other end into the small hole labeled “PFI0”.

  • 18

    Connect BNCs for digital output. Now that you have performed the previous preparatory step, to control the microscope using crucial digital signals you need to connect the following BNC cables (see also Table 1):

  • 19

    Connect shutter control. Connect one end of a BNC cable to the “USER1” port and the other (with a splitter, or splicing the ground and signal wires: see “Splicing a BNC cable to 2 loose wires” in Step 7) to the BNC cable that controls your microscope shutter. Most microscopes use a “high” signal to open the shutter, and otherwise the shutter is closed.

  • 20

    Connect toggling control of the mirrors. If you optionally wish to retain control of your microscope by the original computer at the same time as interfacing your new one, this BNC line is needed to “select source” the control of the mirrors between the two computers. Connect one end of a BNC cable to the “USER2” port, and the other end to the back of the galvanometer control box at the “source” port – on a Prairie microscope for example, this port causes the mirrors to respond to a second source of X and Y commands when the toggle signal is high, and otherwise to respond to the primary source. We thus have our software send a high pulse whenever we are scanning with our “custom” computer.

  • 21

    Enable triggering of other boards. This wire can trigger all other boards. Connect one end of a BNC cable to the “PFI0” port, and the other end to the photoactivation board set up earlier. Now the imaging can trigger the photoactivation.

    Critical At this stage you have a two-photon microscope completely wired for arbitrary computer control, along with triggering of other subsystems. Do not advance until you feel very comfortable running different imaging protocols in conjunction with your other systems – you will want to be able to do this almost automatically once an in vivo preparation is introduced.

Box 1. Fluorescent beads as a stand-in for live neurons during calibration ● TIMING 15 min.
REAGENTS
  • Polybead Polystyrene Microspheres 10 μM (fluorescent beads, 5 ml, Polysciences, cat. no. 17136-5).

  • Ultrapure™ Agarose (Invitrogen, cat. no. 16500-500).

  1. Prepare fluorescent beads sample. Reconstitute the fluorescent beads of a size comparable to fluorescent neurons (10 μm) according to the manufacturer’s instructions with de-ionized water, or for a 3D effect, reconstitute the beads in agar instead of water (according to the manufacturer’s instructions) and add it to a standard 35 mm petri dish.

  2. Use fluorescent beads sample. By adding water on top of the beads sample, and placing it under the objective lens of your 2P microscope, one has a readily accessible stand-in for live neurons during the development and refinement of the imaging apparatus.

  3. Re-use fluorescent beads sample. By storing the sample in the dark between uses, it should be possible to re-use the sample for months. The water that is added in Step 2 may evaporate, but more can simply be added.

Connect computer to microscope for targeted stimulation ● TIMING 4h

  • 22

    Tap into the mirror feedback. Repeat Step 10 with your second galvanometer control box, and a second oscilloscope.

  • 23

    Prepare your computer to control the mirrors. Repeat Step 11 above, again using Computer # 2 and data card # 2b.

  • 24

    Connect computer to the scanning mirrors. Repeat Step 12 above, for Block # 2b, and the second set of mirrors’ control box.

  • 25

    Connect trigger from other boards to this board. Connect one end of a BNC cable to the block’s “PFI0” port, where it will receive a trigger command. To connect the other end to the trigger wires already established for the other blocks, you will use a BNC splitter to fork the output of Block # 2a (the source of the trigger signal) to two destinations. Go to Block # 2a, and replace the BNC wire going into Port “PFI0” with a BNC splitter. Re-attach the detached BNC wire to one end of the splitter. Finally, attach the BNC cable from earlier in this step to the other end of the splitter. Now Blocks # 1 and 2b are connected by trigger wires emanating from Block # 2a.

  • 26

    Configure the computer to use your data cards. Refer to “Starting the Software > Loading Rig Settings” in Supplementary Note 1. Everything should be set as in the code example, except for 3 variables that you need to define for your system, as described in the following 3 steps.

  • 27

    Configure your data card addresses. Configure “Dev1”, “Dev2”, etc. for each card in both computers. One way to find this is to install the NiDAQ Manager that comes with the cards, which will list the card models and their addresses.

  • 28

    Configure mirror maximum voltages. Maximum voltages represent how much voltage your mirrors expect to turn 100% to the edge of the field of view. A typical range is 2.5 V = maximum X, -2.5 V = minimum X. Applying a voltage of zero should center the mirrors. Check with your 2P vendor, or within any existing computer software from your vendor, for a likely source of these values.

    Caution Incorrect values could overload your mirrors and cause them to fly off the microscope.

  • 29

    Configure mirror polarity. Mirror polarity determines what you want to consider positive and which should be negative, based on the layout of the rig and your personal preference – which mirror command directions in X and Y should correspond to “right” or “up” in the image, respectively. Verifying the layout can be achieved by imaging the corner of a known fluorescent substance and verifying that it is oriented correctly in the image.

    Critical Entering these settings and making the above connections means that all of your wiring and configuration is done for both sets of mirrors and the photoactivation system.

(Optional) Expression of optical actuators/reporters in mice ● TIMING 2-6 weeks

  • 30

    Inject virus with optical actuator and/or reporter. For experiments involving mice expressing optical actuators/reporters, follow the procedures published in10,24 to infect the brain circuit and cell type of interest with an optical actuator, such as ChR2. For ChR2, we have observed that some usable expression is available after 1-2 weeks.

    Critical Several weeks (e.g. 6 weeks) may be needed to observe robust expression of your optical actuator or reporter.

    ?Troubleshooting

Prepare animals and network for optical interaction ● TIMING 3 h

  • 31

    Perform craniotomy to expose network of interest. Carry out a craniotomy and stabilize the preparation under the microscope24, or otherwise make your preparation accessible to the microscope light path.

    Caution Make sure that all animal preparations are carried out under protocols approved by your institution, and in conformance with NIH guidelines and ARRIVE principles.

  • 32

    (Optional) Load reporter into brain region. Load the desired imaging site with an optical reporter, such as Oregon Green BAPTA1-AM24.

  • 33

    Verify expression and loading fluorescence quality. Make sure that everything appears as expected by taking a quick 2P image using your traditional computer.

    Critical Step If cells are not nicely loaded with functional reporter, or if cells do not indicate expression of an optical actuator, it is best to abandon the preparation and start anew.

Perform targeted path imaging ● TIMING 4 h

  • 34

    Prepare software. Download the Network Visor software onto Computer # 2. To use it, save it to a folder on your hard drive, start Matlab, browse to the folder where you saved it, and type “visor”. Refer to the extensive documentation provided here (Supplementary Note 1) for more information on how to use it or replicate it into your own system.

  • 35

    Perform raster image. Now go to your custom imaging computer and take a raster image of the loaded cells of interest. After starting Visor, click the “Raster” button. You can then set the zoom as well. This will use the digital outputs to open the shutter and take control of the mirrors (using the “toggle” signal, see Step 20 above) to drive them while acquiring fluorescence. The result will be a raster image on the screen of your custom computer similar to on your traditional computer.

    ?Troubleshooting

  • 36

    Automatically select cells. Press “Select Cells” on Visor (or use your own software) to have the computer identify the location of all cells in the image, as in Figure 3a. Depending on the imaging conditions you can also use the Cell Detection settings to further optimize the image segmentation. See Figure 3a for an example of rapid cell detection using a watershed algorithm.

    ?Troubleshooting

  • 37

    Automatically compute targeted scanpath. Press “Compute Scanpath” in Visor (or use your own software), to have the computer identify the path to sample all selected cells in the image, as in Figure 3b-h. See the software documentation in Supplementary Note 1, “Targeted Scan Path > Computing Scan Path” to understand how this works.

  • 38

    Perform a targeted scanning imaging session. Have the computer compute the scanpath between all cells in the image.

  • 39

    (Optional) Trigger other systems as well. Ready your sensory stimulation or electrophysiology subsystems to start upon trigger. You can hook this system up to the “trigger ring” of BNCs that you created when wiring imaging and photoactivation together above.

    ?Troubleshooting

  • 40

    Specify how long you wish to scan. Specify the “# Laps”, or duration of scanning, which should be the # Laps/Second (50 for 50 Hz imaging) times the number of seconds for which you want to image. For example, if you want to image for 144 seconds, you would have 7200 laps. After the specified number of laps has been collected, the scanning will terminate.

  • 41

    Start the scanning. Press “Fastscan” and the system will digitally trigger its own board as well as all other subsystems’ boards, and begin their orchestration. Performing scanning in this way will lead to higher-signal imaging data, as described in Figure 4. See the software documentation, “Acquisition > Driving Mirrors and Acquiring” to understand how this works.

    ?Troubleshooting

  • 42

    Save your data. After scanning has completed, press “Save” or instruct your software to save the results. You can then explore the results, including transforming optical signal to spikes using deconvolution methods, as in Figure 5a-b.

  • 43

    Validate deconvolution data. Optionally, validate your deconvolution kernel by concurrently measuring physiological calcium transients and spikes, in vitro or in vivo. See Figure 5c-e.

    ?Troubleshooting

Figure 3. Step-by-step guide to computer-guided imaging with higher signal to noise.

Figure 3

A. In preparation for targeting, a normal raster pattern (see attached code, Supplementary Note 1) is used to acquire cells in the network, and pre-processing (see code) maximizes the dynamic range for cell detection (left). A very fast “watershed” cell detection algorithm is then run (see attached code) that finds the “protruding” cell boundaries (right). B. Once cell boundaries are determined, a “near-optimal” scanpath is computed within the framework using the insightful algorithm from21 (see attached code) that connects line scans across features of interest. C. This scanpath is broken down into X and Y components, scaled to zoom, and delivered out through the mirror command ports. Importantly, the scanpath is also intelligently discretized (see code) so that the majority of sampling points (here, 90%) occur “in cell”, and only a few time points are dedicated to the “jumps” between cells. The scale and direction of the scanpath should be validated using the mirror feedback signals hooked up to an oscilloscope in X-Y mode. D. Such signals can be generated in Matlab, LabVIEW (National Instruments, Austin, TX), or custom neuroscience packages such as ScanImage37 (see Supplementary Note 2), and delivered through the ports in Figure 2. These ports then interface with a microscope as described in Figure 2. E. The accuracy and repeatability can be assessed using test samples, such as fluorescent beads embedded in agarose (see Box 1). Repeating the same XY scanpath on a constellation of beads leads to the acquisition of similar fluorescence profiles on each lap of the trajectory. F. These fluorescence profiles can be mapped back on to the raster image as “heat maps”, to verify that the scanpath production is working properly on your microscope, in this case a custom 2P microscope from Sutter Instruments. G. Same as (F) but demonstrated on a leading commercial 2P microscope (Prairie Technologies). H. The speed of the fast scan acquisition can be arbitrarily defined, and fidelity between mirrors’ target and actual positions (as quantified by fluorescence of targeted cells recovered compared to slow raster) are reasonably possible to achieve even at high speeds (1KHz sampling, on the Sutter).

Figure 4. Enhancement of fidelity of action potential detection via computer-guided imaging in vitro and in vivo.

Figure 4

A. Injecting action potentials into a neuron in slices and measuring the resulting calcium transients observed using different styles of acquisitions. The more complex scanpath signals allow one to spend more time dwelling on cells of interest, and the improvement in signal to noise is evident when comparing “traditional scanning” at 1 Hz and 4 Hz to “smart scan” at 50 Hz. Scale bars: 5 s, 5% dF/F. B. Having this quality of signal allows a more direct correspondence between the calcium signal and the actual spikes observed, with single-spike and double-spike transients being readily resolvable. C. The main improvement in smart scan is due to a much higher proportion of time spent actually sampling cells, compared to traditional scan or even “fast scan” with AODs. Targeted scan avails a many-fold increase in actual sampling, which in the case presented here resulted in ~18 times more time spent collecting emission from cell bodies of interest. D. Another advantage of sampling at high temporal resolution is better estimation of actual AP time. Here, while a 1 Hz slow scan had an average jitter in dF/F peak vs. actual AP that exceeded 1 second and showed large variability, 50 Hz targeted scanning showed a constant offset in peak compared to the actual AP time and almost no variability in that offset, such that it can be empirically subtracted for true precision in estimation. E. Sample visual responses observed in response to drifting gratings at different orientations – shown are the gratings rotating sequentially from 0 to 360 degrees (gray bars), with 4 seconds off alternating with 4 seconds on (bottom). The clean signal can be expanded (top) to resolve micro-peaks that correspond to bursts of activity in sync with the sub-regions of the grating crossing the receptive field. F. This level of signal to noise also avails more accurate interpretation of the data. In this case, we estimate the orientation selectivity index for pyramidal cells (Pyr) and parvalbumin-positive interneurons (PV) from the same network measured via slow (traditional) scan or via targeted scan, and compare them to other cells measured electrophysiologically. Here, either the peak dF/F (imaging) or # of spikes (electrophysiology) measured from each orientation stimulus was quantified and used to compute an orientation selectivity index score24. Targeted scan produces values for OSI in the two cell types that more closely matches electrophysiology than slow scan (“slow scan”: N=26 RFP+ cells, N=173 RFP- cells, P=0.72; “targeted scan”: N=9 RFP+ cells, N=22 RFP- cells, P=0.25; “loose patch”: N=11 RFP+ cells, N=17 RFP- cells, P=0.18). All experiments were carried out under protocols approved by MIT’s Animal Care and Use Committee and conforming to NIH guidelines.

Figure 5. Direct methods for validation of optical signals as action potentials.

Figure 5

A. Image of a cortical cell in an acute slice, filled with Oregon Green BAPTA-1, under simultaneous whole cell patch clamp and 2P imaging, using first CCD imaging (left) and then 2P imaging (right, bottom). Scale bar, top: 25 um, bottom: 100 μm. B. Methodology for quantifying accuracy of deconvolution. Top, black: visually evoked spike trains were recorded in vivo and then replayed to the imaged cell via the carefully calibrated injection of current at specific spike times. This resulted in patterns of action potentials that were also recorded electrophysiologically. Middle, blue: Simultaneous targeted fast-scan two-photon imaging during the evoked spike train enabled the optical capture of the cell’s complex response. Middle, red: A “peeling” deconvolution algorithm22 was applied to these waveforms to decompose the signal into single-spike waveform events that we assume sum linearly at moderate frequencies. Bottom, black: Each single-spike event is then attributed to a spike time, and the “optically resolved spike times” are compared to the actual spike times for accuracy in the algorithm’s estimation. C. Comparison of the distribution of spike times recorded (top left) vs. predicted from the optical signal (bottom left) to assess the accuracy in identifying and resolving spikes (96% inter-spike intervals [ISI] bins correctly placed). The actual and predicted ISI are also compared (top right, mean deviation between individual ISI = 0.012 s). Finally, the temporal fidelity (predicted vs. true time in ms) was quantified (bottom right), showing that our optical prediction algorithm was adept at identifying the spikes and their locations with tight temporal accuracy (mean jitter between actual and predicted spike time = 8 ms). D. Implementing this algorithm in vivo allows us to resolve optical spike trains from populations of neurons simultaneously. Shown are traces from 6 different neurons. Scale bars: 5 s, 15 dF/F %. E. These spike trains could be visualized either by projecting the dF/F signal into color space (top) or by plotting the spike trains in space (bottom). Each shaded bar represents the time of presentation (4 secs) of a drifting visual grating of one orientation. The two depictions (top and bottom) are reasonably well-matched, providing another way to diagnose and troubleshoot the accuracy of deconvolution methods.

Integrate the photoactivation laser and focus the beam ● TIMING 1 d

  • 44

    Connect the laser to the SMA-FC/PC fiber. Screw the matching SMA end of the fiber into the end of the laser. With the laser on, tighten the screw and use the micro-positioning knobs to fully align the fiber with the laser beam. You should see a laser shooting brightly and clearly out of the end of the fiber once things are maximally aligned. You can also shoot the laser into the receptacle of an optical power meter to verify a strong signal. For most optogenetic purposes, you want the majority of the laser’s specified power to be registered on the other end of the fiber. A minimum of 25 mW is probably mandatory, though in practice we have found up to 150 mW to be useful.

    Critical Step Make sure that your fiber is effectively coupled to the laser and that bright light can pass through. Improper coupling is a major cause of experimental variability.

  • 45

    Connect the SMA-FC/PC fiber to the microscope. Prairie 2P microscopes come with an optional fiber port whereupon the fiber can be screwed into an FC/PC terminal and aligned by an expert technician. In fact, Prairie now offers setups with a photoactivation module fully incorporated at sale. Sutter and other open 2P microscopes allow you leeway to introduce the laser into the light path at any point along the base table.

    ?Troubleshooting

  • 46

    Integrate the fiber light into the light path. If you made use of a fiber port in the step above, the laser is already integrated. Otherwise, if light path expertise is present in your laboratory or you have access to an expert technician, you can join the laser into the light path by using mirrors to direct it towards the second set of galvanometers. Finally, the output of the two sets of galvanometers can be joined by a dichroic mirror, as is standard with Prairie microscopes (760SP) that allows the high-wavelength imaging (2P) laser to pass through, while the lower-wavelength photoactivation laser is bounced into the same light path.

  • 47

    (Optional) Use a second, independent 2P laser for stimulation. Two-photon excitation of neurons using a beam that is focused49-51 or expanded52 can be accomplished by using a second beam alongside imaging with the primary 2P laser, by swapping out the dichroic that joins the two beams above (760SP), and replacing it with a 50%/50% coupling beam splitter (see the Equipment section) that enables both beams to pass at least half their energy at any wavelength. This allows stimulation and recording at comparable wavelengths. Note: each laser will of course have to be used at twice the strength as before to achieve the same effect.

    ?Troubleshooting

  • 48

    Focus the laser light onto the galvanometer mirrors. Introduce a focusing lens into the light path (this may be part of the integrated “PA” unit from Prairie Technologies described in the Equipment section, which also includes the adjustable aperture in the next step). This allows you to aim the laser light onto the center of the mirrors, which are in conjugate planes with the back of the objective, to uniformly fill the back of the objective whereupon it will come out of the objective as a small focused spot. The distance of the lens can be adjusted as this spot gets blurrier (more diffuse) or tighter (brighter and more focused). This lens will ideally be removable (e.g., see Prairie Technologies) so that you can toggle between targeted photoactivation and full-field photoactivation. For this and the following step, assistance from an expert technician is recommended.

  • 49

    Add a pinhole aperture. Still greater spatial resolution can be achieved by introducing a pinhole into the laser’s light path (see integrated “PA” unit from Prairie Technologies described in the Equipment section). This pinhole will ideally be adjustable so that you can open and close the pinhole to toggle between small-spot, targeted photoactivation, and full-field photoactivation. In the Prairie system and other configurations, the aperture is adjusted with a knob that tightens to shrink the pinhole down to size. For the smallest size (greatest targeting resolution) the user should tighten this as much as possible without causing the spot to disappear, or breaking the knob.

Calibrate “all-optical” interaction with full-field stimulation ● TIMING 1 d

  • 50

    Verify general setup. At this point you should be able to trigger the photoactivation laser in arbitrary time and intensity patterns, and see it coming out of the objective. You should concurrently be able to perform 2P imaging of fluorescently labeled cells. Opening the photoactivation aperture to 100% should allow you to conduct full-field stimulation, and verify that you can broadly stimulate cells within the field of view.

  • 51

    Prepare for full-field optical activation without imaging. A cell can be recorded electrophysiologically while practicing optical activation. Focusing on optical troubleshooting in isolation allows you to remove all uncertainty surrounding optical recording. Once optical activation is routine, it can in turn be used to rehearse robust optical recording. Here, use standard whole-cell or loose patch electrophysiology to record signals from a ChR2 cell24 in advance of optical activation.

  • 52

    Prepare photoactivation. Then, using the photoactivation computer (computer #1), queue a stimulation amplitude waveform to drive the stimulation laser upon command. A strategy that is likely to work well is to create a 10 Hz waveform with 10 ms pulse widths (start with maximal amplitude and then turn it down until you are balanced at minimal effective stimulation). Queue up this waveform, set the photoactivation software on that computer (your own code, commercial software, or code similar to “Stimulation > Driving a Photoactivation Laser” in Supplementary Note 1) to begin upon trigger, and start the computer listening for trigger.

  • 53

    Deliver full-field optical activation during electrophysiological recording. Both the imaging software (e.g. Visor) or the electrophysiology recording software can be configured to digitally trigger the different subsystems (electrophysiology recording board, the photoactivation board, and any other subsystems you have connected) using code such as that described in “Acquisition > Driving Mirrors and Acquiring” in Supplementary Note 1). Starting one of these should trigger the other subsystems, thus commencing photoactivation and electrophysiological recording. You should then see optical light pulses coming out, and see the cell getting stimulated with robust depolarization and action potentials as in Figure 6a-e. Repeat this procedure until you can confidently activate any patched cell expressing ChR2.

    ?Troubleshooting

  • 54

    Practice full-field optical activation with imaging. With routine optical activation verified with electrophysiology, it should be possible to trigger the same optical activation routines while also running the optical recording techniques of steps 34-42. Here, optical activation should lead to responses that can be directly verified through either electrophysiology and/or optical recording (Figure 6f-h).

    ?Troubleshooting

Figure 6. Optimization of reliable optogenetic activation for all-optical physiology.

Figure 6

A. Exact, repeatable depolarization upon brief (1 ms, full-field) channelrhodopsin-2 (ChR2) activation in a Thy1 neuron in a slice of visual cortex. B. In vivo expression of ChR2 in a PV neuron for all-optical interrogation in visual cortex during processing. C. Careful calibration of intensity and duration allows for repeatable, single-spike activation in vivo, in different subclasses of cortical cells (parvalbumin and somatostatin interneurons shown here), and this type of stimulation was successful in other cell types and expression systems in many different attempts and contexts24. D. Light control intensity can be systematically increased, during constant pulse duration (10 ms), to observe a transition from unreliable to reliable spiking. Generally an intensity level should be chosen that provides 100% reliability but is on the lower side of intensity. E. Calibrated activation results in effective and precise cell spiking against a backdrop of physiological activity. F. All-optical troubleshooting is carried out by performing concurrent optogenetic stimulation, 2P calcium imaging, and electrophysiology in acute slices. Pairs of activation pulses should be accompanied by pairs of calcium responses, and verified by pairs of spikes. G. Image of the same cell taken under 2P for calcium imaging (top) and DIC optics (bottom) to facilitate intracellular patch clamp. H. Concurrent traces for voltage delivered to optogenetic laser, two-photon calcium signal recorded, and voltage recorded inside the cell. Again, single spikes and spike doublets can be resolved and all signals match. Note the presence of photo-artifacts from the optogenetic stimulation that must be removed in the analysis, as with electrode artifacts during electrical stimulation. Once this match is achieved, electrophysiology can be removed and “all-optical only” can be attempted. Optical artifacts were removed in analysis using similar algorithms to those for blanking electrical stimuli in electrophysiology. Such artifacts could also be physically blocked by introducing a high-speed shutter in front of the PMTs that closes at high speed in synchrony with optical stimulation.

Align the targeted stimulation laser with the imaging laser ● TIMING 4 h

  • 55

    Prepare for targeted stimulation. With full-field optical activation during imaging verified, the next and final challenge is to shrink the full-field activation into a targeted spot, such that optical energy can be directed to the circuit in a targeted manner (Figures 7a-c). Here, make sure that the focusing lens is in the light path, and the aperture closed as much as possible to let through the smallest spot of light.

  • 56

    Broadly align lasers for targeted stimulation. The two lasers must be made to share a common X-Y reference frame in order for you to stimulate and record things in the same plane. Once you adjust the laser’s aim within the scope so that it hits the back of the objective and passes through, a “target symbol objective” can be used to further align the output of the laser to hit the center of the target. Then, for further micro-alignment, continue with Steps 57-61.

    ?Troubleshooting

  • 57

    Place “burn in” substrate. See also Figure 7d. Place a homogenous fluorescence substance under the objective, and acquire a 2P raster image of it. One straightforward assay for this calibration is to draw on a standard microscope slide with a conventional green fluorescent marker.

  • 58

    Zero the mirrors. Go to your stimulation mirrors’ control box, and remove all inputs from X and Y. This will “zero” the mirrors, pointing the laser at the center of the light path.

  • 59

    Burn a spot to see where the laser “zero” is. Turn on your focused, photoactivation spot laser at high intensity, and leave it on for 30-60 seconds. The result will be that you have “bleached” a small hole in the fluorescent sample.

  • 60

    Take another 2P raster image. You should see the small hole. If the hole is far from the center of the image, macro-scale manual alignment of the laser beam may be required. Repeat these steps until the laser burn-in spot is close to the center of the image.

  • 61

    Determine error offset. Then, to micro-adjust the targeting of the stimulation laser, determine how many pixels away from the center the hole is. Based on your zoom, these pixels can be corrected by supplying an additional offset voltage every time that you stimulate. You can understand the offset voltage by looking at the code (Supplementary Note 1, “Aim at a Cell) and set the offset values in the configuration file where you entered the settings above. Essentially, you will be supplying an added offset voltage to all of your commands to make up for micro-deficiencies in the alignment of the stimulation laser compared to the recording laser. Supplying this offset voltage to the mirrors in software, and repeating the burn-in test, you should see a small, tight bleached spot right in the center of the image, or at other locations that you stimulate (see Figure 7d). At this point you should have the stimulation laser beam integrated into your light path so that it strikes the sample directly through the light path, ideally with the ability to toggle between targeted and full-field photoactivation.

    Critical Step Putting-in the care required for high precision alignment will save much experimental confusion when attempting to functionally target cells during difficult imaging experiments. One strategy for extra precise alignment is to keep repeating the alignment step while zooming in further and further with the raster scan.

Figure 7. Selective optical activation of single neurons in vivo during concurrent optical reporting.

Figure 7

A. Schematic of using two mobile laser beams for optical dissection of circuits. B. Spatial paths burned into fluorescent beads from many passes at high laser power, depicting how independent 2P beams can be driven rapidly around the network in tandem at different transition times, to glide through and sample (top) or “fill in” and stimulate (bottom) various cells or other elements. This can be performed with any laser, using either dual 2P lasers or a 2P laser and a visible laser. C. For the data presented in this figure, we choose to drive a targeted 473 nm laser, the lens of which should be focused until it appears as a tight spot in 3D. Shown is a visualization using a CCD camera. Scaling the intensity of the laser with scale the apparent brightness and size of the spot. D. Depiction of a very useful method for aligning the stimulation laser with the imaging one. First, a raster image is collected of a fluorescent green substrate. This provides a frame of reference from the standpoint of the imaging laser. Then, the stimulation laser is turned on with 0 V applied to X and Y (to “center” this laser). The laser is left on for a long duration (30-60 seconds). The raster image is then re-sampled with the imaging laser, which should produce a “burned in” dot where the stimulation laser falls when centered. Your software commands can then be intentionally altered to compensate for the difference in this burned center (stimulation center) and the image center (imaging center). Trying out different values, at higher and higher zoom, should gradually reduce this difference to near zero. You now have a distinct stimulation laser that you can point and steer while utilizing the imaging laser. E. Spatial resolution of the 473 nm stimulation, obtained physiologically in a patched Thy1 cell in a slice of visual cortex. Diverting the mirror to be either 50 μm from the cell, or directly on the cell, results in no evoked spike vs. an evoked spike. F. Heat map describing the spatial resolution of this targeted activation in 2D. This resolution is comparable in vitro and in vivo at depths that can be imaged24. G. Precision of optical stimulation in vivo. The 473 nm stimulation beam was directed to either an off-target neuron lacking channelrhodopsin (Site A) or a nearly-adjacent channelrhodopsin expressing PV+ inhibitory neuron (red, Site B). Scale bar: 50 μm. H. Optical modulation of PV activity during visual stimulation was then measured in the PV neuron at Site B during either no optogenetic stimulation (visual stimulation alone), intense full-field stimulation, off-target stimulation at Site A, or on-target stimulation of Site B. Relative to Control (visual stimulation only) the full-field and Site B activation resulted in clear additional activation, whereas Site A activation did not. I. An experiment to show no coupling between PV cells, in a network with two PV cells expressing channelrhodopsin. Scale bar: 50 μm. J. Activation of Cell # 2 did not result in coordinated activation of Cell # 1, indicating both a specificity of the activation beam and a lack of sizeable cross-activation among selectively activated cells.

Apply targeted stimulation during imaging ● TIMING 1 h

  • 62

    Ready systems for triggering. Ready the imaging, sensory stimulation (optional) and electrophysiology (optional) subsystems as above in steps 34-40.

  • 63

    Identify a cell to target. In the raster image, note the position in pixels of the cell that you wish to activate.

  • 64

    Aim the beam. Aim the stimulation beam (before turning it on) at the pixel position target of interest, by using code as referenced in the software documentation, “Stimulation > Aim at a Cell”. To activate a given cell, simply deliver sustained X and Y voltage waveforms to hold the mirrors at the desired position. Different locations relative to the cell should result in different efficacies of activation (Figure 7e-f).

  • 65

    (Optional) Apply alternate spatial stimulation patterns. Any pattern can be employed at each cellular vertex, including a rapid spiral with a 2P laser to broadly excite an actuator on the cell surface 49. Multiple in-cell patterns can be directed to multiple cells, with a short amount of time (microseconds or milliseconds) in between. See the software documentation, “Stimulation > Aim at Different Positions”.

  • 66

    Ready photoactivation computer. Repeat Step 52.

  • 67

    Start the scanning. See “Stimulation > Driving Mirrors and Acquiring” in Supplementary Note 1. This will digitally trigger the recording board, the photoactivation board, and any other subsystems you have connected.

  • 68

    Explore the results. After scanning has completed, to verify activation of the cell of interest, look for evoked calcium transients in that cell (e.g. Figure 7g-j), or if that cell is not well loaded / optically responsive, use modulation of the neighboring cells as an assay.

    ?Troubleshooting

Finalize stimulation calibration and commence experiments ● TIMING 1 d

  • 69

    Adjust stimulation to a minimum level. Adjust the intensity of your laser to ensure “minimal stimulation” of the cell’s area of interest, and not of adjacent areas. To do this we recommend following Steps 70-71.

  • 70

    Check stimulation with strong targeted stimulation. Switch to targeted stimulation mode, at high laser intensity, and make sure that you still see the same effect when targeting the cell of interest. If you do not, move on – you are unlikely to be able to perform detectable targeted stimulation with this cell.

  • 71

    Titrate stimulation level. Calibration of stimulation is very important for delimiting its spatial extent in the XY plane (Supplementary Figures 1 and 2) and in the Z plane (Supplementary Figure 3). Once you have a repeatable effect of stimulating the cell, while still aiming at the cell, reduce the intensity of the laser close to zero. You should see the effect disappear. Now keep the stimulation pattern to the laser going, and gradually increase the intensity using your photoactivation software. When you hit a certain point of intensity, you should see your original effect return. Turn the laser back down slightly and the effect should be abolished. Put the intensity back up just a little bit beyond where the effect is reliably evoked, and you should have repeatable but minimal stimulation successfully calibrated. This calibration method is potentially extensible to multiple cells in the field of view. See Figure 7g-j and Anticipated Results.

  • 72

    Commence experiments. Commence network physiology experiments, recording cells throughout the network while modulating a cell or even a subset of cells within the network. Thus you are now optically probing the impact of specific network elements on the distributed activity of the circuit.

Troubleshooting

Troubleshooting advice can be found in Table 2.

Table 2.

Troubleshooting table.

Step Problem Possible reason Solution
1 No laser coming out of fiber Poor coupling Use the screws on the laser port to shift the position of the fiber. Change one screw at a time by small increments, where each change should increase the intensity of the light. A good alignment should be qualitatively obvious.
Damaged fiber Unlikely, but if so try another fiber.
30 No expression / weak expression / partially functional expression of optical actuator/reporter Did not wait long enough for in vivo expression Initially allow very long expression times (6-8 weeks) and then try to shorten them.
Incorrect injection location Perform histology, verify location of injection wound, and check other areas for presence of wound and/or expression.
Nonfunctional virus Try a different batch/preparation of virus. Focus on seeing robust expression in slices under easier imaging conditions before attempting in vivo.
35 No cellular image Mirrors are not moving Try connecting (or forking) your mirror command BNCs to an oscilloscope, to verify that proper “raster” command signals are coming out of the computer.
Verify that the mirror control boxes are powered “on”.
Shutter not opening Verify that you can hear the microscope shutter clicking open and closed when you scan. If not, unhook and re-hook the command lines, and verify that the computer board is not maintaining a “high” signal by resetting the computer.
Microscope switch settings are incorrect. Verify that manual shutter is open, that eyepiece toggle is removed, that camera port toggle is allowing laser pass-through, and that the proper dichroic for 2P is selected in the carousel.
Photomultiplier tube (PMT) not turned up Verify that the PMTs are turned up. You may even turn them up higher to verify that some auto-fluorescence at least registers a signal.
Pockels signal set too low With PMTs set higher than normal, start at low pockels command and then gradually increase until at least an auto-fluorescence signal is registered.
Objective liquid has evaporated with repeated imaging. Verify that objective has contact with the preparation and is immersed in liquid.
36 Automatic cell detection does not lock onto cell bodies Cell detection settings need adjustment If the cell detection module does not seem to automatically “lock” onto cell bodies, or chooses cell bodies of an incorrect size, follow these steps: A) First, make sure that the “Zoom” and “Magnification” in the lower left of the software are set correctly. B) Second, try adjusting the “Cell Detection” sliders in the upper right to work with your particular fluorescence loading or morphology. If the image is reasonably clear then it should work and if not, image quality may need to be remediated.
39 One of the subsystems does not start Incorrect triggering or ready state If one of the subsystems does not start, check that it is connected to the other boards’ triggering cables (see Figure 1), that the subsystems are running and waiting for trigger, and that an error did not occur in the subsystems.
41 No sensory responses Poor indicator loading Repeat loading; may need to abort
Saturated signal The microscope should be calibrated to detect “gray” cells that are neither too dark (insufficient signal; black) or too bright (too much signal; saturated). If cells are registering at this intermediate “gray” level then there should be sufficient response range remaining to detect transients if the cells are active.
Anaesthesia too strong Reduce anaesthesia by 25%, unless animal awakens.
Incomplete indicator loading Wait at least an hour for maximal loading of calcium indicators.
Cells damaged during loading Calcium indicator should be pressure-loaded as slowly as possible, because any extra pressure will disrupt the neurons and reduce uptake.
Brain damage Verify that brain is active with quick loose patch recordings. As one first gets comfortable with evoking sensory responses, electrophysiology (blind loose patch) should be used to ensure that the visual cortex is highly responsive, and to calibrate anaesthesia levels towards this end. Once responses are reliably achievable it is reasonable to switch to imaging wherein the only remaining variables are quality of loading.
43 Fluorescent traces don’t appear to be physiological Cell IDs in data are mis-attributed to cell areas in the image. Make sure that IDs in the data traces match the cells in the image. This can be checked by verifying that the portion of the scanpath that gives rise to the data overlaps with the cell’s actual position, and not another cell.
Mirrors are not fast enough Verify that mirror commands and positions measured via feedback are closely matched
Image fewer cells to reduce the number of turns per lap
Increase the zoom to minimize distance per lap and thus speed
A simple correction can adjust for mirrors that follow the correct command path but with a delay / skidding. Because the mirror feedback is also recorded during scanning, the actual position of the mirrors is known for every recorded sample and can be assigned to the specific cell sampled at that exact moment (or to no cell if the position is traveling between cells). So, even if the mirrors may not have passed the beam through the cell of interest at the exact microsecond planned, it will likely enter it at a slightly later microsecond, and this precise timing is known. By collecting all the samples when the beam was actually passing through a cell and averaging them, one can resolve an accurate estimate of the fluorescence during that lap around the cells, for each cell in the network.
45 Fiber does not connect to microscope port. Incorrect adapter The screw-in nature of this port should ensure a proper coupling. If the terminal does not seem to match, or screwing remains difficult, there may be a mismatch between your configuration and that expected here. In this case, contact your microscope manufacturer for information on proper coupling.
47 After adding a 50/50 mirror, lasers are dim. 50/50 mirror cuts power in half This is expected after adding this mirror; henceforth double the strength of the laser you are using to achieve the same effective strength coming out of the objective.
53 No light-evoked activity Intensity is insufficient Verify that full-field activation is configured and reaching the objective; increase amplitude towards maximum, at 10 Hz and 10 ms pulses.
Cell does not have detectable optical responses Verify responsiveness with sensory stimuli
Optical actuator is insufficient Wait longer for cellular expression
Validate that the optical actuator is functional using a reduced preparation, such as culture or slices, with electrophysiology.
53 Brain damaged by laser activation Light intensity or duration is completely out of range. In our experience it is less common to damage tissue with photoactivation pulses than to damage it with a recording 2P laser that is set too strongly (>100 mW) in an attempt to gather brighter signal, which could damage tissue. As most photoactivation regimes require fast, sparse pulses, this becomes less of an issue. Damage will likely be obvious, with dark (burned) spots appearing in the tissue where the offending laser was.
54 Interference between optical stimulation and recording Inherent in experiment Employ “blanking” in analysis (see “Analysis -Removing Photoartifacts” in Supplementary Note 1).
56 Adapted laser is not centered on lens Misaligned laser path Adjust the position of the laser within the microscope light path in broad strokes until it is centered on the back of the objective. Then, use a screw-in target to make sure that what comes out of the objective port is centered.
68 Stimulation is imprecise in X-Y plane Fiber port aperture is not closed. Tighten the aperture control knob to minimize the size (though avoid closing it completely).
Laser intensity is too high Reduce laser intensity to decrease effective radius.
Beam calibration is off Beam re-calibration should not be required if nothing inside the microscope has been changed, but it may be worth checking using Steps 55-61 of the Procedure.
68 Stimulation is imprecise in Z plane One-photon light has poor Z resolution Perform a Z scan before targeting a cell to ensure that no other cells are above or below the cell of interest.
Apply this Procedure using newer optical actuators or stimulation methods that are amenable to 2P stimulation.

Timing

  • Steps 1-6, Configure computer for basic controlled photoactivation – 1 d

  • Steps 7-8, Connecting computer to photoactivation laser – 1 h

  • Steps 9-21, Connecting computer to two-photon imaging microscope – 4 h

  • Steps 22-29, Connect computer to microscope for targeted stimulation – 4 h

  • Steps 30, Viral infection and actuator/reporter expression in mice – 2-6 weeks

  • Steps 31-33, Prepare animals and network for optical interaction – 3 h

  • Steps 34-43, Perform targeted path imaging – 4 h

  • Steps 44-49, Integrate the photoactivation laser and focus the beam – 1 d

  • Steps 50-54, Calibrate “all-optical” interaction with full-field stimulation– 1 d

  • Steps 55-61, Align the targeted stimulation laser with the imaging laser – 4 h

  • Steps 62-68, Apply targeted stimulation during imaging – 1 h

  • Steps 69-72, Finalize stimulation calibration and commence experiments – 1 d

  • Box 1, Fluorescent beads as a stand-in for live neurons during calibration – 15 min

Anticipated Results

By carefully following the above steps, and testing along the way, the experimenter should be left with a highly robust system for targeted optical recording and stimulation. Following steps 1-8, a photoactivation laser can be controlled with a computer; following steps 9-29, a two-photon microscope can be controlled with a computer; following steps 30-43, two-photon imaging data can be collected using targeted scanning; following steps 44-54, optical stimulation can be done in conjunction with targeted scanning. Finally, following steps 55-72, targeted optical stimulation can be done during targeted scanning. The “full loop” implementation has been achieved when the brain circuit dynamic measured cleanly via optical recording can be perturbed via optical stimulation. Additionally, sample results for each step are shown: Completing the setup as described (Figures 1 and 2, and see Supplementary Data 3-6 for reference) should enable targeted scanning as described in Figure 3c-h. Imaged traces should be comparable to those shown in Figure 4b and 4e, with signal quality to enable deconvolution as in Figure 5d. Optical stimulation can then be introduced, with evoked optical transients comparable to those seen in Figure 6h, and targeted to cellular areas of interest as in Figure 7h, with resolution comparable to that described in Supplementary Figures 1 and 2 in the XY dimension and Supplementary Figure 3 in the Z dimension. We find that once the principles described here are understood and implemented, such imaging and stimulation can be done routinely at the touch of a button. The simplicity of this configuration, combined with the high signal to noise and the opportunity to stimulate individual infected cells non-invasively, make these steps worth the effort for the methodical laboratory.

Supplementary Material

Supplementary Information

Acknowledgments

We sincerely thank the ScanImage team at Janelia Farm, particularly Vijay Iyer, for providing an open platform which others can build on and learn from. We thank Kuan Wang for assistance with the cell detection algorithm. We thank Michael Goard for help with mirror feedback computation, and Sami El-Boustani for help with deconvolution. We thank Volodymir Nikolenko for technical advice, and Prairie Technologies, especially John Rafter, Elizabeth Heins, Patrick Gustafson, Muhammad Nazir, and Curt McCallum for working closely with us during the development of all of these techniques, and providing a stable commercial platform with numerous points of entry for customization. Finally, we thank Bruce Land as a model in scientific communication, whose public sharing of documentation helped in our early days to learn key principles of computer control that could then be extended here.

Footnotes

Nathan R. Wilson & James M. Schummers contributed equally to the work. N.R.W. built the systems, wrote the software, performed experiments and analyses, and wrote the manuscript. J.M.S. conceived the ideas and chain of algorithms that would avail this system, performed analyses, helped develop the software, and helped write the manuscript. C.A.R. improved the system and contributed critical in vivo experiments to validate it, S.X.Y. developed and calibrated the “all-optical methodology”, R.F.C. helped program critical algorithms for cell detection and image motion correction, Y.D. helped initiate and develop the “all-optical” methodology, and M.S. encouraged these developments, steered their application, helped write the manuscript, and supported the refinement of a robust and general protocol applicable to other laboratories.

Competing financial interests

The authors declare that they have no competing financial interests with the material or protocols contained in this manuscript.

References

  • 1.Schwann T, Schleyden M. Microscopical researches into the accordance in the structure and growth of animals and plants. Sydenham Society; London: 1847. [DOI] [PubMed] [Google Scholar]
  • 2.O’Connor DH, Huber D, Svoboda K. Reverse engineering the mouse brain. Nature. 2009;461:923–9. doi: 10.1038/nature08539. [DOI] [PubMed] [Google Scholar]
  • 3.Regehr WG, Connor JA, Tank DW. Optical imaging of calcium accumulation in hippocampal pyramidal cells during synaptic activation. Nature. 1989;341:533–6. doi: 10.1038/341533a0. [DOI] [PubMed] [Google Scholar]
  • 4.Svoboda K, Denk W, Kleinfeld D, Tank DW. In vivo dendritic calcium dynamics in neocortical pyramidal neurons. Nature. 1997;385:161–5. doi: 10.1038/385161a0. [DOI] [PubMed] [Google Scholar]
  • 5.Smetters D, Majewska A, Yuste R. Detecting action potentials in neuronal populations with calcium imaging. Methods. 1999;18:215–21. doi: 10.1006/meth.1999.0774. [DOI] [PubMed] [Google Scholar]
  • 6.Stosiek C, Garaschuk O, Holthoff K, Konnerth A. In vivo two-photon calcium imaging of neuronal networks. Proc Natl Acad Sci U S A. 2003;100:7319–24. doi: 10.1073/pnas.1232232100. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 7.Shoham S, O’Connor DH, Sarkisov DV, Wang SS. Rapid neurotransmitter uncaging in spatially defined patterns. Nat Methods. 2005;2:837–43. doi: 10.1038/nmeth793. [DOI] [PubMed] [Google Scholar]
  • 8.Pettit DL, Wang SS, Gee KR, Augustine GJ. Chemical two-photon uncaging: a novel approach to mapping glutamate receptors. Neuron. 1997;19:465–71. doi: 10.1016/s0896-6273(00)80361-x. [DOI] [PubMed] [Google Scholar]
  • 9.Arenkiel BR, et al. In vivo light-induced activation of neural circuitry in transgenic mice expressing channelrhodopsin-2. Neuron. 2007;54:205–18. doi: 10.1016/j.neuron.2007.03.005. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 10.Cardin JA, et al. Driving fast-spiking cells induces gamma rhythm and controls sensory responses. Nature. 2009;459:663–7. doi: 10.1038/nature08002. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 11.Peron S, Svoboda K. From cudgel to scalpel: toward precise neural control with optogenetics. Nat Methods. 2011;8:30–4. doi: 10.1038/nmeth.f.325. [DOI] [PubMed] [Google Scholar]
  • 12.Schummers J, Yu H, Sur M. Tuned responses of astrocytes and their influence on hemodynamic signals in the visual cortex. Science. 2008;320:1638–43. doi: 10.1126/science.1156120. [DOI] [PubMed] [Google Scholar]
  • 13.Anastassiou CA, Perin R, Markram H, Koch C. Ephaptic coupling of cortical neurons. Nat Neurosci. 2011;14:217–23. doi: 10.1038/nn.2727. [DOI] [PubMed] [Google Scholar]
  • 14.Vervaeke K, Lorincz A, Nusser Z, Silver RA. Gap junctions compensate for sublinear dendritic integration in an inhibitory network. Science. 2012;335:1624–8. doi: 10.1126/science.1215101. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 15.Zhang F, et al. Multimodal fast optical interrogation of neural circuitry. Nature. 2007;446:633–9. doi: 10.1038/nature05744. [DOI] [PubMed] [Google Scholar]
  • 16.Nikolenko V, Poskanzer KE, Yuste R. Two-photon photostimulation and imaging of neural circuits. Nat Methods. 2007;4:943–50. doi: 10.1038/nmeth1105. [DOI] [PubMed] [Google Scholar]
  • 17.Guo ZV, Hart AC, Ramanathan S. Optical interrogation of neural circuits in Caenorhabditis elegans. Nat Methods. 2009;6:891–6. doi: 10.1038/nmeth.1397. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 18.Nagel G, et al. Channelrhodopsin-2, a directly light-gated cation-selective membrane channel. Proc Natl Acad Sci U S A. 2003;100:13940–5. doi: 10.1073/pnas.1936192100. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 19.Boyden ES, Zhang F, Bamberg E, Nagel G, Deisseroth K. Millisecond-timescale, genetically targeted optical control of neural activity. Nat Neurosci. 2005;8:1263–8. doi: 10.1038/nn1525. [DOI] [PubMed] [Google Scholar]
  • 20.Valmianski I, et al. Automatic identification of fluorescently labeled brain cells for rapid functional imaging. J Neurophysiol. 2010;104:1803–11. doi: 10.1152/jn.00484.2010. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 21.Lillis KP, Eng A, White JA, Mertz J. Two-photon imaging of spatially extended neuronal network dynamics with high temporal resolution. J Neurosci Methods. 2008;172:178–84. doi: 10.1016/j.jneumeth.2008.04.024. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 22.Grewe BF, Langer D, Kasper H, Kampa BM, Helmchen F. High-speed in vivo calcium imaging reveals neuronal network activity with near-millisecond precision. Nat Methods. 2010;7:399–405. doi: 10.1038/nmeth.1453. [DOI] [PubMed] [Google Scholar]
  • 23.Rothschild G, Nelken I, Mizrahi A. Functional organization and population dynamics in the mouse primary auditory cortex. Nat Neurosci. 2010;13:353–60. doi: 10.1038/nn.2484. [DOI] [PubMed] [Google Scholar]
  • 24.Wilson NR, Runyan CA, Wang FL, Sur M. Division and subtraction by distinct cortical inhibitory networks in vivo. Nature. 2012;488:343–8. doi: 10.1038/nature11347. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 25.Gerits A, et al. Optogenetically Induced Behavioral and Functional Network Changes in Primates. Curr Biol. 2012 doi: 10.1016/j.cub.2012.07.023. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 26.Adamantidis AR, et al. Optogenetic interrogation of dopaminergic modulation of the multiple phases of reward-seeking behavior. J Neurosci. 2011;31:10829–35. doi: 10.1523/JNEUROSCI.2246-11.2011. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 27.Grinvald A, Hildesheim R. VSDI: a new era in functional imaging of cortical dynamics. Nat Rev Neurosci. 2004;5:874–85. doi: 10.1038/nrn1536. [DOI] [PubMed] [Google Scholar]
  • 28.Tian L, et al. Imaging neural activity in worms, flies and mice with improved GCaMP calcium indicators. Nat Methods. 2009;6:875–81. doi: 10.1038/nmeth.1398. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 29.Chow BY, et al. High-performance genetically targetable optical neural silencing by light-driven proton pumps. Nature. 2010;463:98–102. doi: 10.1038/nature08652. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 30.Li Y, Tsien RW. pHTomato, a red, genetically encoded indicator that enables multiplex interrogation of synaptic activity. Nat Neurosci. 2012;15:1047–53. doi: 10.1038/nn.3126. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 31.Zariwala HA, et al. A Cre-dependent GCaMP3 reporter mouse for neuronal imaging in vivo. J Neurosci. 2012;32:3131–41. doi: 10.1523/JNEUROSCI.4469-11.2012. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 32.Madisen L, et al. A toolbox of Cre-dependent optogenetic transgenic mice for light-induced activation and silencing. Nat Neurosci. 2012;15:793–802. doi: 10.1038/nn.3078. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 33.Sanjana NE, et al. A transcription activator-like effector toolbox for genome engineering. Nat Protoc. 2012;7:171–92. doi: 10.1038/nprot.2011.431. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 34.Miyamichi K, et al. Cortical representations of olfactory input by trans-synaptic tracing. Nature. 2011;472:191–6. doi: 10.1038/nature09714. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 35.Bock DD, et al. Network anatomy and in vivo physiology of visual cortical neurons. Nature. 2011;471:177–82. doi: 10.1038/nature09802. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 36.Alivisatos AP, et al. The brain activity map project and the challenge of functional connectomics. Neuron. 2012;74:970–4. doi: 10.1016/j.neuron.2012.06.006. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 37.Pologruto TA, Sabatini BL, Svoboda K. ScanImage: flexible software for operating laser scanning microscopes. Biomed Eng Online. 2003;2:13. doi: 10.1186/1475-925X-2-13. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 38.Wagenaar DA, Potter SM. A versatile all-channel stimulator for electrode arrays, with real-time control. J Neural Eng. 2004;1:39–45. doi: 10.1088/1741-2560/1/1/006. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 39.Asaad WF, Eskandar EN. A flexible software tool for temporally-precise behavioral control in Matlab. J Neurosci Methods. 2008;174:245–58. doi: 10.1016/j.jneumeth.2008.07.014. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 40.Suter BA, et al. Ephus: multipurpose data acquisition software for neuroscience experiments. Front Neural Circuits. 2010;4:100. doi: 10.3389/fncir.2010.00100. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 41.Katona G, et al. Fast two-photon in vivo imaging with three-dimensional random-access scanning in large tissue volumes. Nat Methods. 2012;9:201–8. doi: 10.1038/nmeth.1851. [DOI] [PubMed] [Google Scholar]
  • 42.Reddy GD, Saggau P. Fast three-dimensional laser scanning scheme using acousto-optic deflectors. J Biomed Opt. 2005;10:064038. doi: 10.1117/1.2141504. [DOI] [PubMed] [Google Scholar]
  • 43.Kerlin AM, Andermann ML, Berezovskii VK, Reid RC. Broadly tuned response properties of diverse inhibitory neuron subtypes in mouse visual cortex. Neuron. 2010;67:858–71. doi: 10.1016/j.neuron.2010.08.002. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 44.Oertner TG. The Lego-logic of optogenetics. Nat Methods. 2011;8:1011–3. doi: 10.1038/nmeth.1771. [DOI] [PubMed] [Google Scholar]
  • 45.Knopfel T. Genetically encoded optical indicators for the analysis of neuronal circuits. Nat Rev Neurosci. 2012 doi: 10.1038/nrn3293. [DOI] [PubMed] [Google Scholar]
  • 46.Yaksi E, Friedrich RW. Reconstruction of firing rate changes across neuronal populations by temporally deconvolved Ca2+ imaging. Nat Methods. 2006;3:377–83. doi: 10.1038/nmeth874. [DOI] [PubMed] [Google Scholar]
  • 47.Vogelstein JT, et al. Spike inference from calcium imaging using sequential Monte Carlo methods. Biophys J. 2009;97:636–55. doi: 10.1016/j.bpj.2008.08.005. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 48.Petreanu L, Huber D, Sobczyk A, Svoboda K. Channelrhodopsin-2-assisted circuit mapping of long-range callosal projections. Nat Neurosci. 2007;10:663–8. doi: 10.1038/nn1891. [DOI] [PubMed] [Google Scholar]
  • 49.Rickgauer JP, Tank DW. Two-photon excitation of channelrhodopsin-2 at saturation. Proc Natl Acad Sci U S A. 2009;106:15025–30. doi: 10.1073/pnas.0907084106. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 50.Hirase H, Nikolenko V, Goldberg JH, Yuste R. Multiphoton stimulation of neurons. J Neurobiol. 2002;51:237–47. doi: 10.1002/neu.10056. [DOI] [PubMed] [Google Scholar]
  • 51.Hirase H, Nikolenko V, Yuste R. Multiphoton stimulation of neurons and spines. Cold Spring Harb Protoc. 2012;2012:472–5. doi: 10.1101/pdb.prot068569. [DOI] [PubMed] [Google Scholar]
  • 52.Vaziri A, Emiliani V. Reshaping the optical dimension in optogenetics. Curr Opin Neurobiol. 2012;22:128–37. doi: 10.1016/j.conb.2011.11.011. [DOI] [PubMed] [Google Scholar]

Associated Data

This section collects any data citations, data availability statements, or supplementary materials included in this article.

Supplementary Materials

Supplementary Information

RESOURCES