The use of a 3D automatic video system that can track individual and groups of zebrafish is described. As application example we explore the effects of the NMDA-receptor antagonist MK-801 on shoals of zebrafish.
Like many aquatic animals, zebrafish (Danio rerio) moves in a 3D space. It is thus preferable to use a 3D recording system to study its behavior. The presented automatic video tracking system accomplishes this by using a mirror system and a calibration procedure that corrects for the considerable error introduced by the transition of light from water to air. With this system it is possible to record both single and groups of adult zebrafish. Before use, the system has to be calibrated. The system consists of three modules: Recording, Path Reconstruction, and Data Processing. The step-by-step protocols for calibration and using the three modules are presented. Depending on the experimental setup, the system can be used for testing neophobia, white aversion, social cohesion, motor impairments, novel object exploration etc. It is especially promising as a first-step tool to study the effects of drugs or mutations on basic behavioral patterns. The system provides information about vertical and horizontal distribution of the zebrafish, about the xyz-components of kinematic parameters (such as locomotion, velocity, acceleration, and turning angle) and it provides the data necessary to calculate parameters for social cohesions when testing shoals.
Zebrafish has become an important model for biological and pharmacological research1-3. Tracking of movement and spatial distribution patterns of individual zebrafish and of shoals of zebrafish is invaluable. Older studies apply manual quantification based on recorded images4. Now, 2D automatic video tracking systems are commonly used5. However, since zebrafish and many other aquatic and nonaquatic animals move in a three-dimensional space, the interest in 3D systems is growing6. The described 3D system was first published in 20077. For technical details and comparisons with other systems see8. The basic advantage of this system as compared to other systems is that it acquires two (optionally three) synchronous and independent views using a mirroring system and that is uses a two-step calibration protocol. In the first step, the 3D-geometry of the stereo system (formed by the camera and the mirrors) is calibrated. In the second step, the nonlinear errors introduced by light refraction are corrected. When studying aquatic animals, the impact of light refraction can be considerable when left uncorrected. Other so far published systems (even newer developments9) omit the two-step calibration procedure. For technical details about object identification, occlusion with multi-object tracking, jigging noise etc. the reader is referred to the original publications8,9. The system has been validated for the study of anxiety-like behavioral responses10,11, shoaling8,11,12 and, in a preliminary study, for antagonistic behavior in zebrafish13. It has also been tested for other fish species (goldfish8, swordtail, tiger barb) and for mice9.
In the following the protocols for calibration and for using the system are described and the results of an experiment testing the effects of the NMDA-receptor noncompetitive antagonist MK-801 on shoaling zebrafish are presented as a representative example to demonstrate the type of data that can be obtained with the system.
Both in the natural environment and in aquariums, zebrafish usually swims in shoals14. Shoaling preferences seems to depend on several factors, such as rearing, sex, and food availability14,15. Interestingly, the distance between individual zebrafish in a shoal becomes smaller when signals of potential danger are present, such as alarm pheromones16 or novelty11. The shoaling paradigm is therefore also being used to test anxiolytic drugs17. Dominance hierarchies18 and social learning19 are fascinating aspect of zebrafish behavior. Because of its highly developed social behavioral character, zebrafish have also become of interest for autism research20,21.
MK-801 has been reported to alter social behavior in zebrafish5,22,23, which is reminiscent of its effects on mammals24. However, MK-801 has also many other effects on other behaviors (such as swimming behavior, inhibitory avoidance and place preference25-27). Therefore it is crucial, in initial experiments to obtain as much information as possible from basic observations. This will provide the basis for designing more targeted experiments.
Survey of the recording apparatus and software
In its current configuration, the observation container (25 cm x 25 cm x 18 cm, L x W x H), holding the zebrafish, is positioned in the observation chamber (91 cm x 46 cm x 56 cm, L x W x H). The chamber also contains a camera, a mirror which is suspended at approximately >45° angle above the container, and LED-light bars. Figure 1 shows a simplified diagram. The camera records both the front view and the top view (mirror) to construct the 3D trajectories of the zebrafish by determining its x-, y-, and z-coordinates. For orientation purposes, the coordinate vectors are presented on the left-front corner of the observation container (position relative to camera), which corresponds with the vectors presented on the 3D views (e.g. Figure 15) generated by the Path Reconstruction Module (see further below). The sampling rate depends on the camera and the computer. In our experiments it is approximately 40 frames/sec (fps). The spatial resolution of the recorded frames is 640 x 480 pixels (this configuration was chosen as optimal balance between spatial and temporal resolution). Windows XP or higher is required.
Before the first recording, the system has to be calibrated to determine locations of the walls of the container and the water surface, to determine the scaling factor of the recorded frames and to adjust for the sizable error generated by refraction of light when passing from water to air. In principle, calibration has only to be performed during the initial installation and after parts of the setup, such as camera or mirror, are moved or replaced. Nevertheless, it is good practice to check from time to time whether the calibration is still correct and recalibrate, if necessary.
The software consists of three modules. The Recordings Module records the frames (two example frames are shown in Figure 2). The Trajectory Module reconstructs the paths for every zebrafish. The Data Processing Module calculates a range of standard kinematic and spatial parameters. For the purpose of further analysis, the data can be imported into spreadsheet or statistical software.
All experiments were conducted in accordance with the National Institute of Health Guide for Care and Use of Laboratory Animals.
1. Calibration
2. Recording
3. Path Reconstruction
4. Data Processing
Six-month old female zebrafish (Danio rerio) of an unspecified ('short-fin') wild-type strain, were purchased from Aquatica Tropicals, Inc. In total 120 zebrafish were used. They were acclimated to the laboratory conditions for approximately 8 weeks in 38 L aquariums before starting the experiments. Water temperature was equal to room temperature (~23° C). Light regimen: 14 hr lights on (6:00-20:00), 10 hr lights off. Zebrafish were fed three times a day: 8:00 Tetra tropical flakes; 12:00 live brine shrimp larvae; 15:00 Tetra tropical flakes. On the days of the experiments, the zebrafish were fed flakes only at 8:00. Immediately after the second recording, the zebrafish were euthanized with 300 mg/L tricaine methanesulfate (MS-222).
For the control group 14 quadruplets (i.e. groups of four zebrafish) were used (n =14), for the MK-801 group 16 quadruplets (n = 16). After 1 hr exposure to 10 µM MK-801 (beginning at 9:30) in 1 L containers, the quadruplets were transferred to the observation containers. Recording was started immediately (at 10:30) and lasted 20 min. Subsequently, the zebrafish were left in the containers for 3.5 hr. During this period, aeration was provided via a tube connected to an air pump. At 14:00 a second 20 min recording was made. The goal of the two recordings was to study the effects of habituation and/or diminishing effects of the drugs (the half-life of MK-801 in rats is about 2 hr28). We analyzed (1) average social distances (also called inter-individual distances11,29) as measure for social cohesion, (2) vertical distribution over ten depth levels, (3) horizontal distribution over four radial zones (see Figure 24A, inset for locations of zones) and over quadrants (see Figure 24B, inset for locations of quadrants), and (4) the three components (x,y,z) of travel distance. The data were averaged per shoal. After Shapiro-Wilkins tests demonstrated that not all variables were normally distributed, Mann-Whitney U-tests were applied for all variables to compare means of control and MK-801 groups. These comparisons were performed separately for the morning and the afternoon sessions. We took α = 0.05/4 = 0.0125, because four (groups of) variables were used (see above).
Figure 2A shows a typical example frame for control zebrafish and Figure 2B shows a typical example frame for zebrafish treated with MK-801, both recorded during the morning session. Notice that the control zebrafish were close to the bottom, close to the front wall (i.e. the side closest to the camera) and stayed closely together (i.e. social cohesion was high). In contrast, the zebrafish treated with MK-801 were close to the top, they did not show any preference in the horizontal plane and they swam at considerable distance from one another (i.e. social cohesion was low). Figure 21 shows representative trajectories. The control zebrafish had a clear tendency to remain at the front side of the observation container. Moreover, they stayed close to the bottom most of the time. Zebrafish treated with MK801, on the other hand, swam anywhere on the horizontal plane. However, they had a clear preference for the upper depth levels at 10:30. At 14:00, their vertical distributions became more homogenous.
Quantitative analysis of the data confirmed our description. Figure 22A shows that the average social distance (i.e. the average inter-individual distances between the four zebrafish of the quadruplets) was for MK-801 zebrafish more than three times as large as for control zebrafish during the morning (at 10:30), with U = 0 and p<0.00001. After 3.5 hr habituation (at 14:00), the social distance in control zebrafish increased, whereas it remained more or less unchanged in MK-801 zebrafish. However, it remained significantly different for both groups (U = 19, p<0.0005) Figure 22B shows the timelines of social distance for the two experimental groups for both 10:30 and 14:00.
The vertical distribution was also very different for both groups. Figure 23 shows that both in the morning (10:30) and in the afternoon (14:00), control zebrafish spent most of the time at the two to three lowest depth levels (i.e. the levels closest to the bottom of the observation container). The MK-801 zebrafish, on the other hand, swam most of the time close to the surface of the water at 10:30 (Figure 23A). After 3.5 hr habituation, at 14:00 they were more or less equally distributed over all depth levels.
The horizontal distribution was also very different for both experimental groups. In Figure 24A we see that MK-801 zebrafish spent less time in the outer zone and more time in the middle and the central zones than control zebrafish did. The differences between groups in regard to the quadrants were even more obvious (Figure 24B). Control zebrafish had a very strong preference for the two front quadrants (1 and 4), i.e. the side of the container closest to the camera. MK-801 zebrafish, on the other hand, were more or less equally distributed over the four quadrants.
As far as kinematic parameters are concerned, we limit the discussion here to travel distance (Figure 25). The MK-801 zebrafish moved more than control zebrafish. Interestingly, this difference was especially significant for the y-component of travel distance. This is the direction of the camera (see Figure 1). Indeed, control zebrafish stayed most of the time close to the front wall in quadrants 1 and 4 (as can be seen in Figures 24A and 24B). MK-801 zebrafish, on the other hand, moved back and forth between front and back halves of the container.
Here, we have presented only a sample of the possible ways to analyze the data provided by the experiment. At this point we restrain from attaching any specific biological interpretation to the results. However, it is worth mentioning that MK-801 has been found to induce social withdrawal30 and reduce social investigative behaviors in rats31 and has been studied as model for negative sumptomes of schizophrenia30. It also caused hyperactivity31, circling behavior32, sensory impairment33, and reduced prepulse inhibition34 in mammals. Although we did not specifically test for those impairments, our findings seem to be consistent with them. More specific experimental setups are required to determine whether the described effects of MK-801 in zebrafish are comparable to those described in mammals. Further analyses and experiments would also be necessary to decide whether anxiety, respiration problems, spatial disorientation, attention deficit, stereotypy etc. played significant roles in the altered behaviors induced by MK-801 in the zebrafish.
Figure 1. Schematic diagram of apparatus. The camera captures frames (i.e. still images) showing both the front view and the top view of the observation tank. The frames are stored in the computer for further processing. Note the locations of the xyz-dimensions, which are important for describing the 3D characteristics of the movements and locations of the zebrafish. The two shaded walls in the figure (and the bottom of the tank) were in our experiment (see Representative Results) painted white, whereas the two other walls were transparent. Click here to view larger image.
Figure 2. Example frames. Note that the front or top views alone are characterized by loss of information. This is especially clearly visible in panel B where the three zebrafish on the left seem to be in close proximity to one another when looking at the front view, whereas the top view shows that this is not true. On the other hand, the top view does not give any indication of the distance from bottom. A) Control zebrafish. B) Zebrafish treated with 10 µM MK-801. Note that the color (blue) of the background was generated by the recording software and was chosen to obtain good contrast. The real color of the walls in the back and on the right and of the bottom was white. Click here to view larger image.
Figure 3. Alignment of side mirror. The white arrow on the left indicates the front wall (closest to the camera) in the side mirror. If two lines are visible, correct the position of the side mirror until only one line is visible (step 1.2). The 5 LEDs of the calibration panel are clearly visible on all three views. Note that because the lights in the chamber are switched on, many other reflections are seen on the LED panel (step 1.4). Click here to view larger image.
Figure 4. Tagging the LEDs. The left panel shows that the five tags (as numbered from 0-4) identified by the calibration procedure do not coincide with the actual LEDs. Besides the LEDs other light spots (in fact reflections) can be seen. On the right panel, gain and shutter were reduced such that only the LEDs are visible. Now the five tags are assigned correctly (as described in steps 1.7-1.10). Click here to view larger image.
Figure 5. Collect container info. The sequence of the six points to be selected (by right-clicking the mouse) is presented. The lines will be drawn automatically. Note that the here indicated numbers do not appear on the screen. When done, press 'Collect container info' (as described in step 1.12). Click here to view larger image.
Figure 6. Collect volume. Right-click the mouse on the indicated locations marking the corners of the water body: first mark the corner in the front view and then in the top view. Then go to the next corner (from 1-8). Note that the eight points mark the outline of the water body, not of the tank. Also note that when right-clicking the mouse only 'x0' appears, which will disappear again when clicking on the next spot (thus the numbers 1-8 do not actually appear on the screen). The procedure is described in step 1.17. Click here to view larger image.
Figure 7. Uncorrected contrast. The image is overexposed and the contrast between fish and background (especially in the front view) is low. Click here to view larger image.
Figure 8. Corrected contrast. The contrast is now improved as compared to Figure 7. Note that the colors on the screen are false colors. Click here to view larger image.
Figure 9. General Settings. After selecting 'Camera control' in the main menu, the 'General Settings' window opens. Deselect 'Shutter' and 'Gain' boxes and use the sliders to find the best contrast between fish and background. Click here to view larger image.
Figure 10. Color settings. In the 'White Balance/Color' window deselect the 'Auto' box and use the 'Red' and 'Blue' sliders to find the best combination for good contrast between fish and background. Parameters. After opening the Trajectory Module, select the experimental file with 'Data location' and then open the 'Parameters' window with 'System Setup'. Good starting values are here assigned to the parameters. Click here to view larger image.
Figure 11. Parameters. After opening the Trajectory Module, select the experimental file with ‘Data location’ and then open the ‘Parameters’ window with ‘System Setup’. Good starting values are here assigned to the parameters. .Click here to view larger image.
Figure 12. Box alignment. Note how the red boxes for the top and the front view define the areas in which the fish might be found. The box to the left is reduced to a line to exclude this area from the search. Click here to view larger image.
Figure 13. Tag assignments. After pressing the 'Start generating trajectories' button and choosing the starting frame (normally frame #0), the 'Tag assignments' window opens. Press 'Step forward' until the tag ('X0') appears on the screen. If the tag is not placed on the image of the fish, press 'No' until it is placed correctly. Then press 'Go'. Click here to view larger image.
Figure 14. Info screen. Panel (A) shows the correct tag assignment. The tag ('X0') is placed on the image of the fish in both views. Usually a line passes through the tag. Panel (B) shows excessive noise and the absence of tag assignment. The frames were acquired from the same recording by changing the color and size thresholds (in step 2.2) from 1,000-50 and 10-5, respectively. Click here to view larger image.
Figure 15. Three-D representation of the reconstructed path. The origin of the arrows is located at the left-front corner of the tank for orientation purposes (see also Figure 1). Thus in this example the fish stays close to the left wall (relative to the camera). Click here to view larger image.
Figure 16. Trajectory smoothing. This window opens after pressing the 'Trajectory smoothing' button. For the time being accept the default value by pressing 'OK'. Click here to view larger image.
Figure 17. Subfolders. The folder generated during recording is shown above. After path reconstruction it contains the six indicated subfolders. Click here to view larger image.
Figure 18. Smoothed file. Top part of an example point.smoothed-file is shown, indicating number of frames, duration of recording (in min), coordinates of center of water body relative to camera, and for every frame the coordinates and the duration. Click here to view larger image.
Figure 19. Data processing. Selecting the files to be analyzed (right window). Click here to view larger image.
Figure 20. Example analysis. The endpoints of interest can be calculated by selecting them from the menu. In this example 'Duration Freezing' was selected. The program asks to provide speed and duration thresholds that define freezing. The result is expressed in percentage of the total duration of the recording. Click here to view larger image.
Figure 21. Representative trajectories. Two representative trajectories for control zebrafish and two representative trajectories for zebrafish treated with 10 µM MK-801 are presented for the morning session starting at 10:30 (upper row) and for the afternoon session starting at 14:00 (lower row). The trajectories for the individual zebrafish of every quadruplet are presented by a different color. However, note that tag swapping might have taken place. Manual correction is required if it is crucial to follow the individual lines. The left front side (origin of the insert arrows) of the depicted container is the side that is closest to the camera (see Figure 1 for positioning of tank). Click here to view larger image.
Figure 22. Average social distance between fish. A) Average social distances for control zebrafish and zebrafish treated with 10 µM MK-801 are presented for the morning and the afternoon sessions. Mean and S.E.M. are presented. ***, p<0.001. B) The timelines of the average inter-individual are presented for both groups. Click here to view larger image.
Figure 23. Depth distribution. A) Distribution of the zebrafish over ten equal depth levels (with level 1 being the level closest to the bottom) for the morning session. B) Distribution of the zebrafish for the afternoon session. Mean and S.E.M. are presented. *, p<0.0125; **, p<0.005; ***, p<0.001. Click here to view larger image.
Figure 24. Horizontal distributions. (A) Temporal distribution over the four radial zones of the experimental groups is presented. The inset shows the locations of the zones from center to periphery: center, middle, outer and combined-corner zones. (B) Temporal distribution over the four quadrants of the experimental groups is presented. The inset shows the location of the quadrants. The walls indicated by double lines represent white walls, those presented by single lines present transparent walls. The camera is located left of the inset, i.e. closest to quadrants 1 and 4 (see also Figure 1). Mean and S.E.M. are presented. Black asterisks denote comparisons between the groups for the morning session and grey asterisks those for the afternoon sessions: *, p<0.0125; **, p<0.005; ***, p<0.001. Click here to view larger image.
Figure 25. Travel distance. The xyz-components of travel distance for the zebrafish during the morning and the afternoon sessions are shown. Mean and S.E.M. are presented. Black asterisks denote comparisons between the groups for the morning session and grey asterisks those for the afternoon sessions: *, p<0.0125; ***, p<0.001. Click here to view larger image.
The experimental procedure shown here allows recording individual zebrafish, pairs of zebrafish (e.g. to study mating or aggression) and shoals of zebrafish (as shown in the representative example). The system is especially suited for simultaneously obtaining information about 3D (vertical and horizontal) distribution, kinematic characteristics (e.g. velocity, acceleration, turning angle) and social parameters (e.g. social cohesion). In the following, we list a few important issues to consider when planning experiments.
Depending on the experimental procedure, different behavioral systems can be studied. For instance, to explore neophobia (i.e. fear for new environments) the recording should be started immediately after introducing the zebrafish to the observation tank (after waiting just for a few seconds for the water to settle down to diminish noise), without prior habituation11,17,37. On the other hand, some research topics might require the zebrafish to be well habituated, for instance when studying the effects of alarm pheromones16. When studying groups of zebrafish, the experimenter should be aware that although the software minimizes switching of tags, it is at this moment not possible to follow individual zebrafish throughout. This is also not important for shoaling studies where the emphasis is on social cohesion, but would be crucial when exploring aggression or mating. Manual reassignment of tags is an option, but can be very time-consuming.
The color of the walls of the observation container and of the observation chamber can have great influence on the behavior of the zebrafish. For instance, white walls have been described to induce aversion responses36, 37. When trying different colors, keep two things in mind: 1) it is important that the front wall (i.e. the wall closest to the camera) remains transparent and that a lid (if one is used) also has to be transparent; 2) when selecting a color never used before, first determine whether the contrast between zebrafish and background is appropriate for recording. Do a test run. Changing the camera settings for recording (Gain, Shutter, Red and Blue, as explained in steps 2.5 and 2.6) and the settings for trajectory reconstruction (e.g. color and size thresholds, as explained in steps 3.3, 3.5, 3.11, and 3.12) can make a big difference. Again, experience with the system will go a long way to decide what is possible.
Depending on the purpose of the experiment, a light source with different characteristics (e.g. spectrum, intensity) might be desirable. The LED bars can easily be replaced. Make sure that the light reaches every part of the container.
If the experiment requires that the zebrafish remains in the observation container for several hours, make sure to provide aeration. An air tube can be attached to the back right corner by using a clip. Check on the computer screen that the clip does not interfere with the recording, i.e. that the zebrafish is at no time hidden from view. In Figures 2A and 2B the black clip can be seen in the top view. Ideally, aeration should be provided before or between recordings, but not during recording as to prevent noise. Also note that switching strong aeration on or off might startle the zebrafish.
If the experiment requires keeping the zebrafish in the container overnight, it is useful to cover the observation chamber with a transparent lid to prevent the zebrafish from leaping out (which is a very common occurrence). If the cover is not removed before recording (as not to disturb the zebrafish), consider the following two points: 1) make sure that the mirror images of the light sources do not obstruct the recording (e.g. by shifting the light sources or by choosing a lid that does reflect light only minimally); 2) consider that the lid might become foggy when used overnight, especially since in this case aeration has also to be provided; one way to reduce this is to choose a lid with small holes in it.
For some experiments it might be essential to determine the baseline behavior of the zebrafish before administering a drug. In this case, the drug can be added between sessions by way of a tube (similar to the aeration tube discussed above).
Although the focus here was on recording zebrafish (Danio rerio), other fish species can, of course, also be recorded with the system. It has been used to study behaviors in (juvenile) goldfish (Carassius auratus), tiger barb (Barbus tetrazona), and green swordtail (Xiphophorus helleri).
Finally it should be noted that other dimensions of the observation tanks are principally possible. However, it would require reconfiguring the system and finding a good balance between spatial and temporal resolution when using much larger observation containers. Furthermore, the shape of the container has to be cuboid. The number of zebrafish or other experimental subjects is theoretically unlimited; however tag swapping increases with number of subjects.
The authors have nothing to disclose.
The authors have no acknowledgements.
AABT-3D Tracking Hardware | xyZfish | AABT II | Includes camera, video card, observation compartment with mirror and lighting |
AABT-3D Calibration Equipment | xyZfish | calib | Contains calibration panel and side mirror |
AABT-3D Observation Containers | xyZfish | cubes | |
AABT-3D Tracking Software | xyZfish | v.1.0 | |
Computer | optional | N/A | Windows XP or higher |
(+)-MK-801 hydrogen maleate | Sigma | M107 | |
Air pump | Fusion | 500 | |
Air line tubing 3/16 in | Lee’s Aquarium and Pet Products | 14508 | |
Medium Binder Clips | OfficeDepot | 561339 | To attach airline to observation container |