Global warming is predicted to profoundly impact ocean ecosystems. Fish behavior is an important indicator of changes in such marine environments. Thus, the automatic identification of key fish behavior in videos represents a much needed tool for marine researchers, enabling them to study climate change-related phenomena. We offer a dataset of sablefish (Anoplopoma fimbria) startle behaviors in underwater videos, and investigate the use of deep learning (DL) methods for behavior detection on it. Our proposed detection system identifies fish instances using DLbased frameworks, determines trajectory tracks, derives novel behavior-specific features, and employs Long Short-Term Memory (LSTM) networks to identify startle behavior in sablefish. Its performance is studied by comparing it with a state-of-the-art DL-based video event detector. Among the negative impacts of climate change in marine ecosystems predicted for global warming levels of 1.5  C to 2  C (e.g. significant global mean sea level rise [1], sea-icefree Artic Oceans [2], interruption of ocean-based services) are the acidification and temperature rise of waters. The behavioral disturbance in fish species resulting from climate change can be studied with the use of underwater optical systems, which have become increasingly prevalent over the last six decades [3,4,5]. However, advancements in automated video processing methodologies have not kept pace with advances in the video technology itself. The manual interpretation of visual data requires prohibitive amounts of time, highlighting the necessity of semi-and fully-automated methods for the enhancement [6,7] and annotation of marine imagery. Tackling Climate Change with Machine Learning Workshop at the 34 th Conference on (NeurIPS 2020). As a result, the field of automatic interpretation of underwater imagery for biological purposes has experienced a surge of activity in the last decade [8]. While numerous works propose the automatic detection and counting of specimen [9,10,11], ecological applications require more complex insights. Video data provides critical information on fish behavior and interactions such as predation events, aggressive interactions between individuals, activities related to reproduction and startle responses. The ability to detect such behavior represents an important shift in the semantic richness of data and scientific value of computer vision-based analysis of underwater videos: from the focused detection and counting of individual specimens, to the context-aware identification of fish behavior. Given the heterogeneous visual appearance of diverse behaviors observed in fish, we initially focus our study on a particular target: startle motion patterns observed in sablefish (Anoplopoma fimbria). Such behavior is characterized by sudden changes in the speed and trajectory of sablefish movement tracks. We propose a novel end-to-end behavior detection framework that considers 4-second clips to 1) detect the presence of sablefish using DL-based object detectors [12]; 2) uses the Hungarian algorithm [13] to determine trajectory tracks between subsequent frames; 3) measures four handcrafted and behavior-specific features and 4) employs such features in conjunction with LSTM networks [14] to determine the presence of startle behavior and describe it (i.e. travelling direction, speed, and trajectory). The remainder of this article is structured as follows. In Section 2 we discuss works of relevance to the proposed system. Section 3 describes the proposed approach. In Section 4 we present a dataset of sablefish startle behaviors and use it to compare the performance of our system with that of a state-of-the-art event detector [15]. Section 5 draws conclusions and outlines future work. Related works to our approach include DL-based methods for object detection in images and events in videos. Deep learning-based object detection for static images. Krizhevsky et al. [16] classify visual features from large datasets. Their work motivated the use of CNNs in object detection, where frameworks perform both localization and classification of regions of interest (RoI). Girshick et al. [17] introduced R-CNN, a system that uses a traditional computer vision-based technique (selective search [18]) to derive RoIs where individual classification tasks take place. Processing times are further reduced in Fast R-CNN [19] and Faster R-CNN [20]. A group of frameworks [21,22,23] referred to as "one-stage" detectors proposed the use of a single trainable network for both creating RoIs and performing classification. This reduces processing times, but often leads to a drop in accuracy when compared to two-stage detectors. Recent advancements in one-stage object detectors (e.g. a loss measure that accounts for extreme class imbalance in training sets [23]) have resulted in frameworks such as YOLOv3 [12] and RetinaNet [23], which offer fast inference times and performances comparable with that of two-stage detectors. Although object detectors such as YOLOv3 [12] can be used in each frame of a video, they often ignore important temporal relationships. Rather than individual images employed by aforementioned methods, recent works [24,15,25,26,27,28,29] used video's inter-frame temporal relationship to detect relevant events. Saha et al. [25] use Fast R-CNN [19] to identify motion from RGB and optical flow inputs. The outputs from these networks are fused resulting in action tubes that encompass the temporal length of each action. Kang et al. [24] offered a video querying system that trains specialized models out of larger and more general CNNs to be able to efficiently recognize only specific visual targets under constrained view perspectives with claimed processing speed-ups of up to 340x. Cos ar et al. [28] combined an object-tracking detector [30], trajectory-and pixel-based methods to detect abnormal activities. Ionescu et al. [27] offered a system that not only recognizes motion in videos, but also considers context to differentiate between normal (e.g. a truck driving on a road) and abnormal (e.g. a truck driving on a pedestrian lane) events. Yu et al. [15] proposed ReMotENet, a light-weight event detector that leverages spatial-temporal relationships between objects in adjacent frames. It uses 3D CNNs ("spatialtemporal attention modules") to jointly model these video characteristics using the same trainable network. A frame differencing process allows for the network to focus exclusively on relevant, motion-triggered regions of the input frames. This simple yet effective architecture results in fast processing speeds and reduced model sizes [15]. We propose a hybrid method for the automatic detection of context-aware, ecologically relevant behavior in sablefish.
We first describe our method for tracking sablefish in video, then propose the use of 4 track-wise features to constrain sablefish startle behaviors. Finally, we describe a (LSTM) architecture that performs classification using the aforementioned features. Object detection and tracking. We use the YOLOv3 [12] end-to-end object detector as the first step of this hybrid method. The detector was completely re-trained to perform a simplified detection task were only the class fish is targeted. We use a novel 600-image dataset (detailed in 4.1) of sablefish instances composed of data from Ocean Networks Canada (ONC) to train the object detector. The detection of each frame offer a set of bounding boxes and spatial centers. In order to track organisms we associate these detection between frames. Our association loss value consists simply of the distance between detection centers in two subsequent frames. We employ the Hungarian Algorithm [13] to generate a loss minimizing associations between detection in two consecutive frames. We then remove any associations where the distance between various detection is greater than 15% of the frame resolution. Tracks are terminated if no new detection is associated with them for 5 frames (i.e. 0.5 seconds-see 4.1). Behavior Specific Features. We propose the use of a series of four domain-specific features that describe the startle behavior of sablefish. Each feature conveys independent and complementary information, and the limited number of features (4) prevents over-constraining the behavior detection problem. The first two features quantify the direction of travel and speed from a track. These track characteristics were selected because often the direction of travel changes and the fish accelerates at the moment of a startle motion. A third metric considers the aspect ratio of the detection bounding box of a fish instance over time. The reasoning behind this feature is the empirical observation that sablefish generally take on a "c" shape when startling, in preparation for moving away from their current location. The final (LMCM) feature seeks to find fast and unstained motion, or temporal visual impulses, associated with startle events. This feature is obtained by convolving the novel 3-dimensional LMCM kernel, depicted in Figure 3, over three temporally adjacent frames. This spatially symmetric kernel was designed to produce high output values where impulse changes occur between frames. Given its zero-sum and isotropic properties, the kernel out-puts zero when none or only constant temporal changes are occurring. We observe that the LMCM kernel efficiently detects leading and lagging edges of motion. In order to associate this feature with a track we average the LMCM output magnitude inside a region encompassed by a given fish detection bounding box. We compare our method with a state-of-the-art event detection algorithm [15]. Section Section 4.1 describes our dataset. Our comparison considers standard performance metrics in Section 4.2 and discusses the potential advantages of semantically richer data outputs in ecological research. The data used in this work was acquired with a stationary video camera permanently deployed at 620m of depth at the Barkley Node of Ocean Networks Canada's 1 NEPTUNE marine cabled observatory infrastructure. All videos samples were collected between September 17 th and October 24 th 2019 because this temporal window contains high sablefish activity. The original monitoring videos are first divided into units of 4-second clips (a sablefish startle is expected to last roughly one second) and down-sampled to 10 frames per second for processing reasons. An initial filtering is carried out using Gaussian Mixture Models [31], resulting in a set composed only by clips which contain motion. For training purposes, these motion clips are then manually classified as possessing startle or not. The Sablefish Startle dataset consists of 446 positive (i.e. presenting startle events) clips, as well as 446 randomly selected negative samples (i.e. without startle events). A second dataset composed of 600 images of sabblefish was created to train the YOLOV3 [12] object detector (i.e. first step of the proposed approach). In order to assess the track-creation performance of the proposed system, we use this custom-trained object detector to derive movement tracks from each of the 892 clips composing the Sablefish Startle Dataset. Tracks with length shorter than 2 seconds are discarded. The remaining tracks are manually annotated as startle or non-startle . This dual annotation approach (i.e. clip-and track-wise) employed with the Sablefish Startle Dataset allows for a two-fold performance analysis: 1) clip-wise classification, where an entire clip is categorized as possessing startle or not, and 2) track-wise classification, which reflects the accuracy in the classification of each candidate track as startle or non-startle. We calculate the Average Precision (AP), Binary Cross Entropy (BCE) loss and Recall for both track-and clip-wise outputs of the proposed system using only the Test portion of the Sablefish Startle Dataset. A threshold of 0.5 (in a [0, 1] range) is set to classify a candidate movement track as positive or negative with respect to all of its constituent points. In order to measure the performance of the clip-wise classification and compare it with the baseline method (Re-MotENet [15]), we consider that the "detection score" of a clip is that of its highest-confidence movement track (if any). Thus, any clip where at least one positive startle movement track is identified will be classified as positive. The conversion from track-wise classification to clip-wise classification is expected to lower the overall accuracy of our proposed approach. A "true" startle event might create only short, invalid tracks, or sometimes no tracks at all. This situation would lower the clip-wise classification performance, but would not interfere with the track-wise one. The track-wise metrics are applicable only to our approach and they mainly reflect the difference between the manual and automatic classification of the tracks created in the dataset by the proposed system, thus evaluating the ability of the LSTM network to classify tracks. Table 2 shows that the LSTM portion of our method performs well for classifying startle tracks (AP of 0.85). Clip-wise, our method outperformed a state-of-the-art DL-based event detector [15] with an AP of 0.67.
Our proposed system generates more semantically rich data by detecting and describing behavior rather than just marking a clip as containing the behavior; this may be helpful for ecological and biological research. Our approach provides instance-level information such as track-specific average speed, direction and rate of change. These extra data may allow for further analyses considering inter-and intra-species behaviors. Also, there are clips that contain more than one startle, and our approach is able to identify all startle instances in such clips. Simply classifying a clip as startle or non-startle would, of course, not allow for the detection of multiple startle instances within the same clip. We propose an automatic detector of fish behavior in videos that performs semantically richer tasks than typical computer vision-based analyses: instead of specimens counting, it identifies and describes a complex biological event (startle events of sablefish). Our intent is to enable long-term studies on changes in fish behavior that could be caused by climate change (e.g. temperature rise and acidificaton). A dataset composed of 892 4-second positive (startle) and negative (non-startle) clips, and associated tracks were manually annotated. Experiments using this data show that the proposed detector identifies and classifies well individual tracks of motion as startle or not (AP of 0.85). Furthermore, the performance of our clip-wise classification is compared to that of a state-of-the-art event detector, ReMotENet [15]. Our system outperforms ReMotENet with an AP of 0.67 (against 0.61). Future work will address more fish behaviors (e.g. predation, spawining) and will adapt DL-based event detectors such as ReMotENet [15] and NoScope [24] to that end.