Foids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets
YUKO ISHIWAKA∗ , SoftBank Corp., JapanXIAO S. ZENG, NeuralX Inc., USA
MICHAEL LEE EASTMAN, SoftBank Corp., JapanSHO KAKAZU, SoftBank Corp., Japan
SARAH GROSS, NeuralX Inc., USA
RYOSUKE MIZUTANI, Nosan Corporation, Japan
MASAKI NAKADA∗ , NeuralX Inc., USA

(a)

(b)

(c)

Fig. 1. (a) 3D salmonids model. (b) Salmonids schooling simulation with Foids . (c) 3D synthetic scene with Foids.
We present a bio-inspired fish simulation platform, which we call "Foids",
to generate realistic synthetic datasets for an use in computer vision algorithm training. This is a first-of-its-kind synthetic dataset platform for
fish, which generates all the 3D scenes just with a simulation. One of the
major challenges in deep learning based computer vision is the preparationof the annotated dataset. It is already hard to collect a good quality video
dataset with enough variations; moreover, it is a painful process to annotate
a sufficiently large video dataset frame by frame. This is especially true
when it comes to a fish dataset because it is difficult to set up a camera
underwater and the number of fish (target objects) in the scene can range up
to 30,000 in a fish cage on a fish farm. All of these fish need to be annotated∗ Yuko Ishiwaka and Masaki Nakada equally contributed to this work.

Authors’ addresses: Yuko Ishiwaka, SoftBank Corp., Japan, yuko.ishiwaka@g.softbank.
co.jp; Xiao S. Zeng, NeuralX Inc., USA, steven@neuralx.ai; Michael Lee Eastman,
SoftBank Corp., Japan, michael.eastman01@g.softbank.co.jp; Sho Kakazu, SoftBank
Corp., Japan, sho.kakazu@g.softbank.co.jp; Sarah Gross, NeuralX Inc., USA, sarah@neuralx.ai; Ryosuke Mizutani, Nosan Corporation, Japan, r_mizutani@nosan.co.jp;
Masaki Nakada, NeuralX Inc., USA, masaki@neuralx.ai.
Permission to make digital or hard copies of all or part of this work for personal orclassroom use is granted without fee provided that copies are not made or distributedfor profit or commercial advantage and that copies bear this notice and the full citationon the first page. Copyrights for components of this work owned by others than theauthor(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or
republish, to post on servers or to redistribute to lists, requires prior specific permission
and/or a fee. Request permissions from permissions@acm.org.
© 2021 Copyright held by the owner/author(s). Publication rights licensed to ACM.
0730-0301/2021/12-ART207 $15.00
https://doi.org/10.1145/3478513.3480520

with labels such as a bounding box or silhouette, which can take hours tocomplete manually, even for only a few minutes of video. We solve thischallenge by introducing a realistic synthetic dataset generation platformthat incorporates details of biology and ecology studied in the aquaculture
field. Because it is a simulated scene, it is easy to generate the scene datawith annotation labels from the 3D mesh geometry data and transformation
matrix. To this end, we develop an automated fish counting system utilizing
the part of synthetic dataset that shows comparable counting accuracy tohuman eyes, which reduces the time compared to the manual process, andreduces physical injuries sustained by the fish.
CCS Concepts: • Computing methodologies → Physical simulation.
Additional Key Words and Phrases: Bio-inspired simulation; Fish schooling;
Physically based animation; Synthetic dataset; Neural network learning;
Deep learning; Fish counting.
ACM Reference Format:
Yuko Ishiwaka, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah
Gross, Ryosuke Mizutani, and Masaki Nakada. 2021. Foids: Bio-Inspired
Fish Simulation for Generating Synthetic Datasets. ACM Trans. Graph. 40,
6, Article 207 (December 2021), 15 pages. https://doi.org/10.1145/3478513.
3480520

1

INTRODUCTION

Salmonid aquaculture is currently one of the fastest growing sectors
in the food industry. In order to protect the health of the fish, and tounderstand how the changing environment may impact production,
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

207:2 •Yuko Ishiwaka, Masaki Nakada, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah Gross, and Ryosuke Mizutani

the behavior and preferences of salmonids is an important area ofinterest in the industry. Past models of sea-caged salmonids have focused on mapping behavioral patterns in swimming configurations
and feeding activity [Cubitt et al. 2003; Juell and Westerberg 1993],
but few have successfully reconstructed the system from a biologicaland ecological perspective. These models give information on how
fish behave in different caged environments, but the findings are
specific to the environment studied. A salmonid behavioral model
based on biological parameters and environmental constraints could
allow farming industry workers to accurately predict the behavior
and movement of their fish in any specific environment and enable
future simulation-based experimentation. This biologically-based
approach can result in more accurate behavior and greater individual variation, producing outputs that allow for investigation into
both individual and population level behavior.
One of the challenges in a fish farm is counting the total numberof fish in a fish cage. Water is the natural enemy of electronics andsensors that could otherwise provide useful information when dry.
In particular, depth sensors are ineffective underwater, and wirelesscommunication, such as Wi-Fi, cannot be used underwater. Sonar
is currently used to detect fish, but although it can find schools offish, the resolution is too low to count individual fish. The only
information we can use for counting fish is underwater camera
images.
Unfortunately, a significant portion of the fish don’t survive until
harvesting, and the number of deaths can vary from week to week.
Therefore, it is important for fish farms to count the total numberof fish from time to time to give a better estimate of market valueof the farmed fish, which should be relative to the quantity andthe size of the fish. In addition, it is important to know the total
number of fish in the cage so that fish farm workers can feed thefish the right amount of food. Most fish do not have a sense ofsatiation, and have a tendency to overeat, which can lead to sickness
or death. Currently, fish are counted one by one manually by eye,or by performing a simple calculation based on the total weight
and weight per individual. These approaches are not ideal. Because
the total number of fish in a cage can range from 200-30,000, it is a
painful process for farmers to manually count them, and estimatingfrom weight is very imprecise, both because of the error resulting
from variation in individual weights, and because of excess water
weight introducing error to the total weight as well. Therefore, itis nearly impossible to count accurately. Manual counting is not
ideal for fish health either, as they need to be lifted into the air for
farmers to do the counting. Farmers use nets for this lifting and thenet can scratch the skin of the fish.
This challenge can be solved by a computer vision algorithm.
Deep learning models trained with a good quality dataset of sufficient quantity have proven adept at vision tasks. A quality dataset
should contain many training examples consisting of input-output
pairs, where the input is normally either raw images or video, andthe output is annotated labels. When creating a dataset for visiontasks involving fish, it is time consuming to travel to the ocean andcapture enough videos with many variations (time, season, quantityof fish, fish size, cage shape, latitude and longitude, etc.), and moreover, it is a daunting task for humans to label the data manuallywhen the number of labels can be as many as 30,000 per frame.
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

We apply computer graphics to solve this problem. Specifically, we
synthesize a realistic dataset using a biologically- and ecologicallybased simulation technique, which enables us to generate a datasetof unlimited size without a manual annotation step.
To solve the fish counting problem, we propose an automatedfish counting system. A video camera is placed in a fish cage, and a
trained deep neural network estimates the total number of fish.

2

RELATED WORK

There are only a few datasets available for computer vision whenit comes to underwater scenes. Australian Institute of Marine Science (AIMS) and University [2019] developed a dataset of 80k images
with 45K 2D bounding box annotations, which contained 507 fish
species. Deepfish [Saleh et al. 2020] collected a dataset of 40k images
with associated classification labels, 3,200 labels for counting, and
310 segmentation masks. Ditria et al. [2021] collected 9,429 imagesof luderick and annotated them with classification labels. Unfortunately, we could not use these datasets to train our fish counting
algorithm for several reasons. Firstly, they are limited to Australianfish species. They had to be annotated manually; hence the size andthe variation of the datasets is limited. Additionally, they all havefew fish per image and backgrounds that are very dissimilar to fish
farms.
Ditria et al. [2021] and Tarling et al. [2021] applied data augmentation techniques to enhance a fish dataset, and succeeded inincreasing the size and the variation of the dataset; however, theannotated data only contain photos of fish taken from the side. To
detect and count fish in a fish farm, images from a bottom perspective are also needed, but additional perspectives cannot be createdthrough data augmentation. Furthermore, data augmentation of thissort, where 2D images are overlaid, is not physically accurate andlacks components such as shadows, occlusion, reflections, and depthof field, especially when many overlapping fish are added.
Varol et al. [2017] proposed a synthetic dataset approach for humans (SURREAL), which enabled them to generate more than 6
million images with ground truth labels of pose, depth maps andsegmentation masks by superimposing an animated character withdifferent poses taken from motion capture data onto a various 2D
scene background images. They proved that a synthetic data approach can be used to increase the size of the dataset which can beutilized for computer vision algorithm training. Hwang et al. [2021]
proposed ElderSim which generates synthetic data platform for action recognition. PHAV [de Souza et al. 2017] is a synthetic data
generation platform for gaming. Dosovitskiy et al. [2017] proposeda platform named CARLA for autonomous driving systems. CARLA
provides 3D CG assets of various actors, vehicles, sensor suites, environmental conditions, and so on. Matthews et al. [2020] generated
a synthetic dataset based on the dataset by Ghorbani et al. [2020].
Although the effectiveness of using synthetic data in training deeplearning models is now well established, such a synthetic dataset
does not yet exist for the problem of fish counting.
Tu and Terzopoulos [1994] proposed a fish simulation with perception, cognition and muscle based locomotion. LINDSEY [1978]
defined 12 types of locomotion in fish, and Satoi et al. [2016] incorporated this definition and proposed a controller which automaticallyFoids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets •selects a type of locomotion based on a desired target behavior.
Couzin et al. [2011] simulated consensus decision making based on
experiments using a small group of fish and showed that the decisions of a group depend on the distribution of informed individuals
and uninformed individuals. Katz et al. [2011] experimented to infer
the structure and dynamics of interactions in 2-30 Notemigonus
crysoleucas and showed that three-body interactions make a substantial contribution to fish dynamics. Although those methods
worked well at simulating individual fish behaviors, they were notdirectly useful for our objective because we needed a way to simulate the fish on a larger scale on the order of tens of thousands of fish,
while forming schooling behavior organically through interactions
among the fish.
Boids [Reynolds 1987] successfully simulated a flock of birds with
3 simple rules for spatial coordination among members of the same
species. It was further extended by Podila and Zhu [2017b], Stephenset al. [2003], and Podila and Zhu [2017a], who introduced predatorprey relationships to diversify the resulting animation. However,these methods are not suitable for a caged environment because
the space is protected by a net; hence, predator-prey interaction
cannot be expected. Reynolds [1999] proposed a method for steering
behaviors for autonomous characters in computer animation andgames, and succeeded in generating various motions autonomously,
such as achieving a goal while avoiding obstacles in a Boids simulation. Satoi et al. [2016] proposed a trajectory planning method witha tube for Boids simulation to allow artists to control the animation; however, this was highly artificial, and moreover, it does notscale well when generating many variations. Furthermore, these
proposed methods based on the Boids model were missing key ecological behavioral responses which come from temperature, lightintensity, and boundary effects from the net and the water surface,which greatly contribute to the fish behavior in caged underwater
environments.

3 BIOLOGICAL BACKGROUND
3.1 Schooling in Cages
While schooling in a farmed environment appears similar to swimming in the wild, the reasons behind the need for schooling differs
greatly and therefore, the intentions and decisions in the schoolingbehavior are unique to the situation. Schooling in cages occurs as
the result of creating optimal personal space for each individual
fish, while still being able to move around [Juell 1995]. When thesalmonids in the cage reach a certain crowding density threshold,they begin to form what appears to be a circular schooling pattern inorder to best avoid collisions with one another, consistent with the
Boids model [Oppedal et al. 2011]. In contrast, schooling in the wild
is not constrained to a certain area, and fish form schools that swim
far and wide for reasons such as energy efficiency and protection
from predators [Marras et al. 2015; Pavlov and Kasumyan 2000].
In the caged environment, schooling appears primarily regulated
by visual stimuli [Juell 1995], and the fish’s lateral line system also
helps to regulate schooling behavior by allowing the fish to feel thevibrations of the swimming patterns of the fish surrounding them
[Bleckmann 2004]. The fish orient themselves primarily to the fishin front of them, and accelerate according to the fish surrounding

207:3

them in the front and back, speeding up if they are too close to thefish behind and slowing down if they are too close to the fish in
front [Herbert-Read et al. 2011].

3.2

Vertical Distribution of Fish

Often fish in sea cages appear to settle into two or three distinct
layers of salmonids grouped vertically in the cage [Cubitt et al. 2003].
This group layering phenomenon is likely a product of combined environmental influences such as crowding density, light intensity, andtemperature preferences. Fish have individual preferences that varyslightly and are distributed throughout the vertical space accordingly [Føre et al. 2009]. Additionally, the fish eye is slower to adjust
to changes in light; this is likely a significant factor in the unique
vertical grouping of the caged salmonids. The size of the salmonids
is also a large factor in the vertical grouping of the schooling fish,
and is likely a big component in influencing some of the differencesin preferences between the fish. Fish typically group in shoals withsimilarly sized fish [Krause et al. 1996] and bigger fish tend to go todepths of greater water density, which is found lower in the cage atlower temperatures, while smaller fish swim faster higher up above[Folkedal et al. 2012; Hvas et al. 2021]. Implementing these specificparameters of small preferential differences among the fish and thesize of the fish allow the model to accurately reproduce the detailed
aspects of sea-caged schooling behavior.

3.3

Temperature

Salmonids prefer cooler temperatures overall and will exhibit thermoregulatory behavior–changing their swimming patterns or vertical alignment–based on the surrounding water temperature [Reynolds
and Casterlin 1979]. Generally, younger salmonids prefer slightly
warmer temperatures compared to older salmonids. Salmonids are
typically raised for 6-15 months until they reach the adult stage. But
just under a month after hatching, salmonids will regulate closer tocommon adult temperature ranges in the 8-9 degrees Celsius range[Jensen et al. 1989].

3.4

Crowding

The density of the caged population is one of the biggest influencing
factors affecting the behavior of salmonids in captivity. The circularschooling pattern characteristic to caged salmonids is not a case ofclassic schooling, but rather is a product of the fish avoiding colliding
with one another at high stocking densities. Schooling begins at adensity of approximately 243 individuals/2000m3 (0.1215 fish/m3 ),with consistent, uniform schooling patterns observed at a thresholdvalue of 729 individuals/2000 m3 , or at approximately 0.3645 fish/m3[Oppedal et al. 2011]. This circular swimming pattern allows forsalmonids to maintain some movement while avoiding collisions
with one another and maintaining a preferred distance from the sidesof the cage [Sutterlin et al. 1979]. According to literature values,
fish maintain a distance of at least 0.66 body lengths (BL) awayfrom their neighbors [Føre et al. 2009]. There is also much researchthat shows the intelligence of these fish, and that they will learn
to not swim into cage walls [Brown et al. 2007; Odling-Smee andBraithwaite 2003]. Salmonids are known to be a higher intelligencefish species who have the capacity to remember their pathway home
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

207:4 •Yuko Ishiwaka, Masaki Nakada, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah Gross, and Ryosuke Mizutani

across thousands of miles of ocean [Dittman and Quinn 1996; Nevitt
et al. 1994]. This memory serves them well in a caged environment
where salmonids prefer to stay at least 0.25 meters from the very
top or very bottom of the cage during normal daylight hours, withthe exception of feeding times, and on average stay about 1.0 meters
away from the sides of the cage if possible [Føre et al. 2009]. The
inclusion of the memory component adds depth to the previous
Boids model in which trajectory decisions were made based only
on current information.

3.5

Light Intensity

Daylight patterns have arguably the largest influence on swimming
patterns in caged salmonids. Salmonids have little movement atnight and start to increase movement as the sunlight increases atthe start of the day, eventually swimming in a circular, school-likepattern around the cage [Huse and Holm 1993]. Light intensity also
affects the vertical distribution of salmonids. Fish swim closer to thesurface of the water during the nighttime and travel lower downin the cage during the day [Fernö et al. 1995]. This stark change inswimming behavior from day to night is an important factor in thesimulation and will likely be highly beneficial to salmonid farming
industry workers who will be able to better predict the behavior of
their fish without disturbing the cage environment when they areunable to physically see them in the dark.

3.6

Decision Making Interval

The Mauthner cells (M-cells), which exist in 95 % of fish species, are apair of large and easily identifiable neurons located in the hindbrain.
M-cells handle risk avoidance , which triggers a C-start as a rapid
escaping movement when a risk event happens. The role of M-cells is
not limited to risk avoidance. It is also a command neuron which acts
as a neural decision-making cell [Wiersma and Ikeda 1964], [Kornand Faber 2005]. [Miller et al. 2017] showed that the neural circuit
including M-cells is involved in decision making in social groups
using zebrafish (Danio rerio). They found that action potentials for
swimming lasted for a duration of 50-200 ms and are repeated aftera C-start movement is triggered. Although zebrafish and salmonids
are different fish species, both have a similar M-cell size [Zottoli
1978]. It is known that the response of the action potential has
similar characteristics in the same cell type [Hodgkin and Huxley
1952] even in different species, but varies with body temperature.
To be precise, slower responses occur at lower temperatures [Reyes
et al. 2008]. Salmonids have a lower body temperature than zebrafish.
Therefore, we set the decision-making interval for our salmonids
simulation to 200ms, the lower end of the processing speed range.

4

Fig. 2. Architecture of the Foids simulation framework.

FOIDS SIMULATION

We propose a novel fish simulation framework, Foids (Fig. 2), thatrealistically emulates the swimming patterns of salmonids in commercial cages by introducing multiple factors that simultaneously influence salmonids behaviour. The traditional Boids model [Reynolds
1987] is improved in order to allow salmonids to form schools inan environment free of external constraints. Additionally, we add
boundary constraints to the activity space of salmonids to mimic thescene inside a commercial sea cage. Underwater light intensity and
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

temperature variations are also included in our simulation framework since both of them are important environmental drivers ofswimming depth preferences of fish [Føre et al. 2009; Oppedal et al.
2011]. We furthermore integrate the salmonids decision-making interval and two alternating swimming modes [Sfakiotakis et al. 1999]
as intrinsic factors in fish movement into the framework to simulate
fish’s reaction to changing conditions. Each of the above-mentioned
components will be explained in this section. Note that expressionsof the form [𝑥, 𝑦, 𝑧] and bold letters a, d and v are used to represent
directional 3D vectors. The bold letter p denotes a point in 3D space.

4.1

Improved Boids Model for Fish

The conventional Boids algorithm has three pillars that are simple
rules governing the interaction of individual agents. We adopt all
three rules and improve them in our proposed framework. We provide a description of them below in order of decreasing precedencewith regard to our simulation.
Separation: a fish attempts to swim away from neighboring fishto avoid collision. This is achieved by computing a change in velocity (Δv𝑖𝑗 ) for a target fish 𝑖 and every other neighboring fish 𝑗 of the𝑁𝑠 neighbors within a distance threshold (𝑟𝑠 ). This delta velocity has
an opposite direction to the location of the neighbor, and fish 𝑖 does
not respond to any individual 𝑗 if their distance (|d𝑖 𝑗 |) is equal to or
larger than the threshold. These delta velocities are accumulated andaveraged by 𝑁𝑠 to yield a mean delta velocity, which is then multiplied by a separation weight (𝑤𝑠𝑖 ) to obtain a separation-induced

Foids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets •delta velocity (Δv𝑠 ). This process can be expressed as follows:((𝑟𝑠 − |d𝑖 𝑗 |) d𝑖 𝑗 if |d𝑖 𝑗 | < 𝑟𝑠𝑖
Δv 𝑗 =®0otherwise
(1)
Í𝑁𝑠
𝑖
Δv
𝑗
𝑗=1
Δv𝑠 = 𝑤𝑠𝑖
𝑁𝑠
The variable d𝑖 𝑗 represents a 3D vector spanning from a neighboring fish 𝑗 to fish 𝑖 that we compute separation for. The separation neighbor detection distance 𝑟𝑠 has a default value of 3 bodylengths (BL), which follows the setting in [Føre et al. 2009]. The
term (𝑟𝑠 − |d𝑖 𝑗 |) is a distance coefficient that controls the strengthof separation influence that depends on distance between the two
fish. The separation weight parameter 𝑤𝑠𝑖 is set to be 30 BL, andis set the highest among weights of the three Boids rules to give
salmonids strong motivation to keep distance from their neighbors
in a crowded space such as a sea cage.
Alignment: a fish attempts to align its velocity to that of neighboring fish. In a conventional Boids model, alignment is a predictive
version of separation [Reynolds 1987], and it is accomplished by
calculating the average velocity of all other fish within an alignment
distance threshold (𝑟𝑎 ) of a target fish 𝑖. We adapt this approach byadding a distance term (𝑟𝑎 − |d𝑖 𝑗 |), where d𝑖 𝑗 is the vector pointing
from a neighbor 𝑗 to the target fish 𝑖, that endows closer neighbors with higher alignment influence and penalizes the influence ofdistant neighbors. We multiply this distance term with the instantaneous velocity v 𝑗 of such neighbor fish 𝑗 to obtain a weighted
velocity (v ′𝑗 ) of each flockmate within the distance threshold 𝑟𝑎 . The
results are accumulated and then averaged to compute the weighted
mean velocity ( v̄neighbors ) of all 𝑁𝑎 neighbors. We further calculate the discrepancy between the velocity of target fish (v𝑖 ) andv̄neighbors . This discrepancy is multiplied by an alignment weight(𝑤𝑎𝑖 ) and the result is used as an alignment-induced delta velocity(Δv𝑎 ) for fish 𝑖 as shown in Eq. (2):((𝑟𝑎 − |𝑑𝑖 𝑗 |) v 𝑗 if |d𝑖 𝑗 | < 𝑟𝑎
′
v𝑗 =
0®
otherwiseÍ𝑁 𝑎 ′(2)
𝑗=1 v 𝑗v̄neighbors =𝑁𝑎Δv𝑎 = 𝑤𝑎𝑖 ( v̄neighbors − v𝑖 )where the weight parameter 𝑤𝑎𝑖 is given a value of 12 BL since
we assume alignment plays a smaller role in the effort made bysalmonids to prevent collision. The alignment detection distance 𝑟𝑎
is valued at 3 BL in the default setting.
Cohesion: a fish attempts to stay close to neighboring fish. This isachieved by calculating an cohesion-induced delta velocity (Δv𝑐 ) fora target fish 𝑖 that brings it closer to the average position (p̄𝑛𝑒𝑖𝑔ℎ𝑏𝑜𝑟𝑠 )of 𝑁𝑐 neighbors within a cohesion detection distance threshold 𝑟𝑐 .
The computational procedure is similar to that of alignment but
without a distance term. The reason there is no distance term in Eq.
(3) is that, when schooling, each fish is only affected by the average
position of its neighbors relative to its own position, and thus the
distance to each individual neighboring fish becomes irrelevant.
Any other fish with a distance to fish 𝑖 equal or greater than 𝑟𝑐 does

207:5

not elicit a reaction in fish 𝑖. Eq. (3) illustrates the steps used toobtain Δv𝑐 :Í 𝑁𝑐
𝑗=1 p 𝑗p̄neighbors =(3)𝑁𝑐
Δv𝑐 = 𝑤𝑐𝑖 ( p̄neighbors − p𝑖 )where p𝑖 is the 3D position of fish 𝑖 and thus the difference betweenp̄𝑛𝑒𝑖𝑔ℎ𝑏𝑜𝑟𝑠 and p𝑖 determines direction of cohesion-induced delta
velocity. The difference is also multiplied by a cohesion weightparameter 𝑤𝑐𝑖 with a value of 0.1 BL. The cohesion detection distance𝑟𝑐 is consistent with the value of separation and alignment detection
distances, which is 3 BL.

4.2

Boundary Constraints

A common sea cage for salmonid farming contains two types ofboundaries: aquaculture nets that form the sides and bottom of thecage and the water surface at the top of the cage. To model the
behavioural response towards these boundaries, we assign the fish
a preferred distance to boundaries (𝑟 pref ) and check if its distances
to cage walls (𝑟 wall ), bottom (𝑟 bott ) and water surface (𝑟 surf ) are lessthan the preference. If any of these distances drop below 𝑟 pref , thefish swims away from the corresponding boundary as described in
Eq. (4):Δvbound = Δvwall + Δvbott + Δvsurf
Δvwall = max(𝑟 pref − 𝑟 wall, 0)(𝑤 rb dca + 𝑤 fb cos 𝜃 fb dhoriz )Δvbott = 𝑚(𝑤 rb + 𝑤 fb cos 𝜃 fb ) max(𝑟 pref − 𝑟 bott, 0) dup(4)

Δvsurf = 𝑚(𝑤 rb + 𝑤 fb cos 𝜃 fb ) max(𝑟 pref − 𝑟 surf, 0) ddown
The variable Δvbound denotes the accumulated delta velocity
induced by boundary avoidance and is composed of Δvwall , Δvbott
and Δvsurf that correspond to the cage walls, the cage bottom, andthe water surface. Each of these components consists of a regularboundary avoidance factor and a front boundary avoidance factor.
The regular boundary avoidance factor influences the fish wheneverits distance to a boundary is below the preferred range 𝑟 pref . For acage wall, this factor is computed using the vector dca that points
to the center axis of the cage from the fish and the weight 𝑤 rb that
controls the sensitivity. For the cage bottom and the water surface,dca is substituted by a vertical unit vector that points upward (dup )or downward (ddown ).
The front boundary avoidance factor takes effect only when aboundary is not only close to but also in front of the fish. Given therotation of the fish, we calculate the angle (𝜃 fb ) between its moving
direction and outward-pointing normals to all boundaries within
the 𝑟 pref . A degree between -90 and 90 for 𝜃 fb indicates the boundary
is ahead of the fish. The variable cos 𝜃 fb controls the magnitude of
the front boundary avoidance factor. It is multiplied by either dup ,ddown or dhoriz which are horizontal unit normal vectors pointed
inward from each boundary. The weight parameter 𝑤 fb controls thesensitivity of this factor.
After the summation of the aforementioned two factors, we use
the difference between preferred and actual distances to the boundary to govern the overall scale of the response. We also add a parameter 𝑚 with a default value of 2.5 to intensify the delta velocities
against the cage bottom and water surface since there are more
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

207:6 •Yuko Ishiwaka, Masaki Nakada, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah Gross, and Ryosuke Mizutani

vertical changes in velocity than horizontal ones in our simulation.
This is caused by light and temperature effects and will be discussed
in further detail in the following sub-sections. The values of 𝑤 rb and𝑤 fb are both set to be 1 BL, while 𝑟 pref is valued at 4 BL because we
assume salmonids have a strong tendency to avoid colliding withboundaries.

4.3

Light Effects

Our model of light effects on salmonid schooling is a combinationof the approach taken in [Føre et al. 2009] and a day-night switching model, which is necessary because salmonids have distinct behaviour patterns during day and night [Johansson et al. 2006]. In
the daytime when light is sufficient, salmonids swim faster, stayin deeper layers of the cage and are more likely to form circlinggroups. In order to simulate the relationship between lighting andsalmonids behaviour, we preset a range of preferred light intensities(𝐼 lpref , 𝐼 hpref ) for salmonids and estimate the under-water ambient
light intensity (𝐼 ) using the Beer-Lambert law as shown in Eq. (5):𝐼 = 𝐼 surf × 𝑒 −𝑎𝑧(5)where 𝐼 surf is the light intensity on the water surface, 𝑎 is an attenuation coefficient and 𝑧 is the vertical position of the fish. 𝐼 surf is valued
at 519.69 PAR at noon based on the average illuminance measured
at a salmonid farm (Table 3) and changes with time throughout theday. The attenuation coefficient 𝑎 is set to be 1.5 in our framework
because it varies from 1.5 to 1.9 in sea water according to [Murty
1969]. A deviation of 𝐼 from the preferred light intensity range triggers a vertical delta velocity (Δvlight ) for each fish. This is computed
as:
𝐼
−𝐼


if 𝐼 ≤ 𝐼 lpref
 𝐼 lpref− 𝐼lsteep [0, 1, 0]
Δvlight = lpref
(6)
𝐼
−
𝐼
hpref

 𝐼hsteep − 𝐼hpref [0, −1, 0] if 𝐼 ≥ 𝐼 hprefwhere parameters 𝐼 lsteep and 𝐼 hsteep control the steepness of thereaction to light and are given default values of -7 and 409 PAR. We
set 𝐼 lpref and 𝐼 hpref to be random values between 1.1 and 4.5, and
3.5 and 7 PAR because light preference interval can differ amongindividuals. These parameter settings are identical to those in [Føreet al. 2009]. If the 𝐼 hpref selected for a fish is lower than 𝐼 lpref , wereset the value of 𝐼 hpref to be the midpoint of its value range. whichis 5.25 by default.
In addition to adjusting their depth in water, fish respond to lightintensity changes in the simulation by drastically altering theirswimming pattern at sunrise and sunset. The swimming speed is
set to be between 0.2 and 1.9 BL during the day and between 0 and
0.4 BL at night based on the study of [Oppedal et al. 2011]. The
alignment and cohesion weights, boundary avoidance weights andneighboring fish detection distances are all decremented after sunset
by a factor (𝑠) that equals the ratio of night speed to daytime speedof fish. These changes slow down fish and undermine their ability toform circling groups at night. At sunrise, the modified parameters
are again incremented by the inverse of the same factor 𝑠 so that
their normal values are used throughout the day.

4.4

Temperature Effects

We employ an improved version of the temperature response model
developed by Føre et al. [2009] to simulate the effects of temperature
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

(a) Near-surface ocean temperature(b) Deeper ocean temperature
Fig. 3. The ocean temperature model in the Foids framework consists ofa near-surface layer and a deeper water layer. (a) Temperature differences
between near-surface sub-layers (grey, red, orange and green star symbols)and deeper ocean (blue star symbol) at daytime and night reproduced
from [Kawai and Wada 2007, Figure 1]. (b) Deeper ocean temperature
measured by expendable bathythermograph (dashed line) and conductivitytemperature-depth (solid line) instruments reproduced from [Abraham et al.
2013, Figure 10].

on salmonids. We preset a range of preferred temperatures (𝑇lpref ,𝑇hpref ) for salmonids and compare the under-water ambient temperature (𝑇 ) with the range to determine whether the fish should
swim upward or downward. We use a two-layer method to obtain 𝑇
based on the studies by [Abraham et al. 2013] and [Kawai and Wada
2007]. Fig. 3 illustrates the temperature changes in the near-surface
and deeper layers of the ocean. Note that in the near-surface layer(Fig. 3a), the water temperature drops approximately 1 ◦ C from thewater surface (the grey star symbol) to the sub-layer at a depthof 1 meter (the green star symbol). In the deeper water layer (Fig.
3b), the water temperature remains constant at depths between 1
to 20 meters. Therefore, given a water surface temperature (𝑇surf ),we linearly decrease (𝑇surf ) by 1 ◦ C from depths of 0 to 1 meters tocompute 𝑇 , and keep 𝑇 constant below 1 meter as the sea cage isonly 6 meters deep in our simulation.
We use the obtained 𝑇 together with parameters controlling thesteepness of response to temperature (𝑇lsteep and 𝑇hsteep ) to calculate

Foids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets •the temperature induced vertical delta velocity (Δvtemp ) as follows:𝑇−𝑇 𝑇lpreflpref− 𝑇lsteep [0, 1, 0]

if 𝑇 ≤ 𝑇lpref(7)
𝑇 − 𝑇hpref 𝑇hsteep − 𝑇hpref [0, −1, 0] if 𝑇 ≥ 𝑇hprefwhere 𝑇lpref , 𝑇lpref are set to be 8 and 9 ◦ C based on the findingsof [Jensen et al. 1989]. 𝑇lsteep and 𝑇hsteep are valued at -60 and 80◦ C respectively in a similar manner to [Føre et al. 2009] in order tomoderate fish’s reactions to under-water temperature variation.𝑇surf
has a value of 8.3 ◦ C at noon to match the collected water surface
temperature data (Table 2) and it changes over time throughout theday.
Δvtemp =4.5

Control Cycle

We integrate a salmonid control cycle into the proposed simulation
framework by designating the update rates of the implemented rules
to match the elapsed time of the sensory system in salmonids. We set
the salmonoids’ interval time to respond to environmental stimuli(Δ𝑡 res ) to be 200 milliseconds in accordance with the literature study
described in Sec. 3.6.
Given that each simulation time step takes Δ𝑡 sim , we update thecomputation of the improved Boids rules, boundary constraints,
light and temperature effects every ⌊Δ𝑡 res /Δ𝑡 sim ⌋ simulation steps.
We sum the delta velocities induced by these factors to obtain an
accumulated delta velocity (Δvsum ) at the beginning of each update
cycle for individual fish and a delta change per simulation step
(Δvstep ) is derived as shown in Eq. (8):Δvsum = Δv𝑠 + Δv𝑎 + Δv𝑐 + Δvbound + Δvlight + Δvtemp
Δvsum
Δvstep =⌊Δ𝑡 res /Δ𝑡 sim ⌋(8)where the Δvstep is applied to adjust the fish velocity during the
update of fish movement at every simulation step.

4.6

207:7

Algorithm 1 summarizes the workflow of the fish behavioral
model, and the parameters used in the simulation are described inTable 1.

ALGORITHM 1: Foids simulation𝑡 ← 0;
Δ𝑡 sim ← Simulation time step;v ← 0.2 BL;
while simulation is running do
Update neighbor observation;
if t >= 200 milliseconds thenCompute light induced delta velocity Δvlight ;Compute temperature induced delta velocity Δvtemp ;Compute boundary avoidance induced delta velocity
Δvbound ;Compute separation induced delta velocity Δv𝑠 ;Compute alignment induced delta velocity Δv𝑎 ;Compute cohesion induced delta velocity Δv𝑐 ;Compute Δvstep using all the induced delta velocities;𝑡 ← 0;endv ← v + Δvstep ;if switching from rapid mode to hovering mode thenDecrease v, range of speed, alignment and cohesion weightsof the fish by multiplying them with 𝐻 active ;else
if switching from hovering mode to rapid mode thenIncrease v, range of speed, alignment and cohesion
weights of the fish by dividing them with 𝐻 active ;end
end
Update position and orientation using v;
𝑡 ← 𝑡 + Δ𝑡 sim ;end

Swimming Mode

We further improve the fidelity of fish simulation by incorporating
two locomotion modes for salmonids based on the swimming mechanism research in [Sfakiotakis et al. 1999]. The first mode is a rapid
mode where fish move in their normal speeds with designated Foids
weights, while the second mode is a hovering mode where individuals significantly diminish their speeds and response to Foids rules
by multiplying an activeness parameter (𝐻 active ) for the purpose ofhovering. We assume the fish in the lower part of the sea cage havesome probability (𝐻 start ) to start in the hovering mode as simulation
begins and all other individuals should start with rapid locomotion.
A hovering fish has a tiny probability (𝐻 switch ) of switching to rapid
mode if either it moves into upper part of the sea cage or its angleof elevation surpasses a threshold (𝜃 et ). Similarly, a rapidly moving
fish has a tiny probability (𝐻 switch ) of switching to hovering mode
if either it moves into the lower part of the sea cage or its angle ofdepression exceeds a threshold (𝜃 dt ).
The probability parameter 𝐻 start is valued at 0.01 to ensure theamount of hovering fish is small. Thresholds 𝜃 et and 𝜃 dt are set to
23 and 11 degrees respectively to limit the vertical rotations allowed
for hovering individuals as they prefer stabilization.

4.7

Animation

The realism of the simulation is further increased by animating theswimming motion of each fish using a finite state machine. Statetransitions and the amount of blending between animations are
determined by values taken from the current state of the Foids
simulation. Furthermore, the speed of animation playback is also
adjusted based on fish speed from the simulation. A total of elevenanimations are divided among three states, each containing one ormore blend trees.
Hover: A state corresponding to the hovering swimming mode in
the Foids simulation. A blend tree blends between a resting animation and a slow swimming animation, depending on the speed of
the fish.
C-start: A state that is triggered when a fish switches from thehovering mode to the rapid mode. A left- or right-oriented animationis chosen, based on the sign of the rotation of the fish.
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

207:8 •Yuko Ishiwaka, Masaki Nakada, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah Gross, and Ryosuke Mizutani

Table 1. Foids simulation parameters
Description

Symbol

Unit

Value

Body length
Detection range for separation
Detection range for alignment
Detection range for cohesion
Preferred distance to boundaries
Weight of separation response
Weight of alignment response
Weight of cohesion response
Weight of regular boundary avoidance
Weight of front boundary avoidance
Multiplier of vertical boundary avoidance
Lower bound of preferred light intensity
Upper bound of preferred light intensity
Steepness parameter of light reaction
Steepness parameter of light reaction
Light intensity at water surface
Light attenuation coefficient
Swimming speed in daytime
Swimming speed at night
Lower bound of preferred temperature
Upper bound of preferred temperature
Steepness parameter of temperature reaction
Steepness parameter of temperature reaction
Temperature at water surface at noon
Probability to hover at start of simulation
Probability to switch swimming mode each frame
Elevation angle threshold for swimming mode switch
Depression angle threshold for swimming mode switch
Activeness parameter for hovering mode

BL
𝑟𝑠
𝑟𝑎
𝑟𝑐
𝑟 pref
𝑤𝑠
𝑤𝑎
𝑤𝑐
𝑤 rb
𝑤 fb
𝑚
𝐼 lpref
𝐼 hpref
𝐼 lsteep𝐼 hsteep
𝐼 surf𝑎𝑣 day𝑣 night
𝑇lpref𝑇hpref𝑇lsteep
𝑇hsteep
𝑇surf
𝐻 start𝐻 switch
𝜃 et𝜃 dt
𝐻 active

m
BL
BL
BL
BL
BL
BL
BL
BL
BL
N/A
PAR
PAR
PAR
PAR
PAR
N/A
BL/second
BL/second
◦C
◦C
◦C
◦C
◦C
N/A
N/A
DegreeDegreeN/A[0.392, 0.588]
3
3
3
4
30
12
0.1
1
1
2.5
[1.1, 4.5]
[3.5, 7]-7409
[0, 519.69]
1.5[0.2, 1.9][0, 0.4]
8
9
-60
80
8.3
0.01
0.00005
23
11
0.17(strength, speed, etc.), underwater transparency, sun light attenuation, sun light intensity, sun light color, fish count, fish swimming
speed, social distancing among fish, and fish behavior response sensitivity to boundaries, light, and water temperature. Because oursimulation implemented these physics and biology elements, we cansynthesize a dataset of any size automatically within the constraintsof physical reality, which contains many variations observable in
the real world.
The input dataset is a sequence of rendered images from thesimulation scene. The output dataset contains 2D bounding box, 3D
bounding box and silhouette data, which can be useful for various
computer vision algorithm training including detection, recognition,
tracking, localization and region proposal.
Fig.6 shows some examples of a synthesized dataset. One of theadvantages of computer graphics is that it is easy to compute thecoordinates of the fish in pixel and 3D world space in the scene. This
allows us to compute the 2D/3D bounding boxes which are stored
as the labeled dataset for the scene. Likewise, the silhouette of the
fish in 2D pixel coordinates can be easily computed by projecting
the fish geometry to screen space, and can be used as an annotateddataset to train segmentation algorithms such as Mask R-CNN [Heet al. 2017].

6
Swim: A state corresponding to the rapid swimming mode in the
Foids simulation. A blend tree blends between four swimming animations, of varying speeds and intensities, and four turn animations,depending on the speed and rotation of the fish.
At the start of the simulation, a fish is set to either the Hover stateor the Swim state, based on the swimming mode randomly assignedby the Foids simulation. Upon changing from the hovering modeto the rapid mode, a transition from the Hover state to the C-start
state is triggered, followed by an automatic transition to the Swim
state after completion of the C-start animation. Upon changing fromthe rapid mode to the hovering mode, the state machine transitions
from the Swim state to the Hover state. Each frame, the simulation
determines if a transition should be triggered, and also updates the
speed and rotation variables used by the blend trees.
Speed: The magnitude of the velocity of the fish is mapped fromthe range [0, maxSpeed] to [0,1], where maxSpeed is set by the Foids
simulation based on the body length of each fish.
Rotation: The signed angle between the current velocity vector
and a previous velocity vector from 10 frames ago is calculatedaround the fish’s up vector from 10 frames ago. The result is added toa weighted moving average to determine the fish’s current rotation.
A positive value is a rightward rotation and a negative value is a
leftward rotation.

5

SYNTHETIC DATASET

We synthesize a dataset of input-output pairs using the simulation
pipeline with the Foids model described in Sec. 4. The physics andbiology parameters in the simulation are randomly set within therange of physical reality. The available parameters include but are
not limited to latitude, longitude, time of the day, date, year, waves
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

FISH COUNTING SYSTEM

The fish counting system consists of 3 modules: image pre-processing,detection, and counting modules as shown in Fig. 4. The detection
model is based on one of the state-of-the-art region proposal algorithms, YOLOv4 [Bochkovskiy et al. 2020] which we modified andtrained with the synthetic dataset we generated using the Foids
simulation. The input of the pipeline is a sequence of video frames,
and the output is a list of proposed bounding boxes (x, y, w, h),where (x,y) is the coordinate of the top left corner of the boundingbox, and w and h are the width and height of the bounding box,
respectively, with an associated class label and a confidence score.
We set the confidence score threshold to be 0.5 and the proposed
regions below the threshold are discarded.
Image Pre-Processing: This module transforms the input video toan image sequence and applies denoising and fisheye lens distortion
correction to convert the original video data to the desired format forthe detection module. The denoising process applies median blur tothe images to reduce the effect of noise which can be introduced byvarious factors such as garbage and caustics in underwater scenes.
The fisheye correction module is applied to repair distorted images
due to the fisheye lens, which we utilize to capture scenes with awider field of view (FOV). Our fish eye lens has a 235 degree FOV.
The output of this module is a sequence of repaired-perspective
images with suppressed noise, which are fed to the detection module.
Fish Detection: Fig. 5 shows the fish detection architecture. It isbased on the YOLOv4 architecture. A sliding window is added asa first layer of the network to solve false negative problems withsmaller fish. Each window crops a sub-image 𝑆𝐼𝑖 with a size of
416x416 from the original image 𝐼 , and the sliding window shifts
half of its size horizontally and vertically in an iterative manner, andproduces an R number of 𝑆𝐼𝑖 . which is then fed to YOLOv4 network.

Foids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets •207:9Fig. 4. Fish counting pipeline. It consists of image pre-processing, detection, and fish counting modules. The image pre-processing module denoises andcorrects fisheye distortion, and feeds the processed data to the detection module. The detection module takes the processed image frames, and then outputs
the number of fish in each frame. The final fish counting module computes the maximum value of all the estimated values from detection module, which wetake as the final output of the estimation.

Fig. 5. Fish detection model network architecture. This module is a region proposal network based on the Yolo-v4 model, which is trained with our synthetic
dataset. A sliding window is added as a first layer to crop sub-windows to magnify smaller fish in original images, which effectively avoids false negatives
during smaller fish detection.

cropped images into a single array with a shape of 𝐾 ∗ 𝑅(5 + 𝐶),
and then we apply Non-Maximum Suppression (NMS) to produce asingle output, unlike the standard YOLO where the NMS is appliedjust after a single detection block.
(a) Scene(b) 2D and 3D bounding boxes(c) Silhouette

Fig. 6. Synthetic dataset example. (a) Scene rendering which is useful as
an input dataset of computer vision models. (b) and (c) are output datasetsof computer vision models. (b) is the 2D and 3D bounding boxes which areuseful for the training of region proposal models. (c) is a silhouette dataset
which is useful for segmentation models.

Counting: After the detection module completes, we evaluate theestimated number of fish in each frame and compute the max of thedata, which we take as the final estimated value of the fish count ina cage. Regardless of its simplicity, the MAX method gives us thehighest accuracy in the counting.

7

EXPERIMENTS AND RESULTS

We conducted multiple experiments. All the animation results areincluded in our supplemental video.
The number of the generated image, 𝑅, is computed by the Eq. 9.
𝐼ℎ𝑒𝑖𝑔ℎ𝑡 − 𝑆𝐼ℎ𝑒𝑖𝑔ℎ𝑡
𝐼− 𝑆𝐼 𝑤𝑖𝑑𝑡ℎ+ 1) × (+ 1)
𝑅 = ( 𝑤𝑖𝑑𝑡ℎ
𝑠
𝑠

7.1
(9)

, where 𝑆𝐼 𝑤𝑖𝑑𝑡ℎ and 𝑆𝐼ℎ𝑒𝑖𝑔ℎ𝑡 are the width and height of the sliding
window, and 𝐼 𝑤𝑖𝑑𝑡ℎ and 𝐼ℎ𝑒𝑖𝑔ℎ𝑡 are the width and height of theoriginal image, respectively. 𝑠 is a step-size term and is set to be halfof the sliding window size.
This technique magnifies small fish in the original images. The
processing speed slows down by 𝑅 with this extra step using a
serial computational process; however, it contributes to reducing
the number of false negatives which is a major problem with theoriginal YOLOv4. Note that we concatenate all the result from theReal Scene vs Foids Simulation

Because our goal is to synthesize a dataset to train a computer vision algorithm that detects and counts the number of fish in realscenes, we assessed the quality of our work by comparing the visual
similarity between the captured videos and simulation. The valuesof light and temperature parameters we used are described in Sec. 4.
Fig. 7 shows the comparison between the image sequences fromthe captured video in the real environment and our Foids-based
simulation. The two scenes look similar. Note that both fish schooling behavior and the environmental effects, including light, watercolor, bloom, and reflection of the light, were reproduced well inour simulation.
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

207:10 •Yuko Ishiwaka, Masaki Nakada, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah Gross, and Ryosuke Mizutani

7.4(a) Sequence of frames from the captured video in the real environment
around 11am. The details of the experiment are described in Appendix A

7.5(b) Sequence of animation frames generated by our simulation at 11am.
Fig. 7. Comparison of the scenes captured from a side view around 11am:(a) Real scene (b) Foids simulation.

7.2

Real Environment vs Boids Simulation vs Foids
Simulation

Fig.8 shows a comparison between Boids and Foids-based schoolingsimulations. We added the boundary avoidance rule to the Boids
model in order to conduct a fair comparison with Foids. Boids works
well in the open air for birds; however, there are some discrepancies
when compared to the behavior of real fish in a caged environment,
which are caused by missing details in the implementation froma physics and biology standpoint explained in Sec. 3. Specifically,
Boids lacked a temperature effect, light intensity effect, and cage net
and water surface avoidance, which makes the resulting animation
quite different from the real behavior. Furthermore, the resulting
animation is quite monotone as there are no predators or obstaclesin the fish cage, which is usually the way to introduce variability inBoids-based animations. With Foids, we implemented the aforementioned additional factors, which resulted in schooling behavior that
more closely resembled the real behavior. Note that there was somepercentage of fish that either hover or did not follow the schooling
pattern, which was what we observed in the real environment andwas missing from the Boids-based simulation.

7.3

Simulation at Different Times of Day

Fig. 9 shows a sequence of frames from an animation at different
times of day. Because our goal is to synthesize a dataset to train arobust computer vision model which works well in any environment,
it is better to prepare a training dataset captured at different times ofthe day as the underwater scene looks quite different in the morningand in the evening. This platform further enabled the changing oflocation without any real-world travel, which dramatically reduced
the data acquisition cost. Note that it takes several days or months
to capture data with these variations in real environments, and then,the data have to be manually annotated.
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

Synthetic Dataset

Fig. 10 shows the example of the dataset generated by our synthetic
scene. The ocean color changed over time as well as lighting, fish
behavior pattern, the number and size of fish, the temperature of
the water, etc., which we used as an input training dataset of ourfish counting module. Fig.11 shows some examples of the annotateddataset with 2D bounding boxes, which we used as the output
training dataset of our fish counting module.
We synthesized the dataset of 10,000 input-output pairs by running the simulation on an Nvidia GeForce 2080 GPU installed in a
Windows 10 system with a 3.2GHz Intel Core i7 CPU. Each pair ofthe data took approximately 0.3 seconds to generate.

Fish Counting System

Fig.12 shows some example images of the fish counting system witha video captured in a real fish cage. The trained fish counting algorithm estimated the number of fish in each frame, and the total
number of fish was computed by taking the max of the estimatedvalues while the network processes all the video frames. The estimated fish count by fish counting system was 264. In comparison,
the fish count estimated by human vision was 272.

8

CONCLUSIONS AND FUTURE WORK

We presented a fish simulation platform which is built based on
findings in biology and ecology, which aims to produce an extensive
and high-quality training dataset for computer vision algorithms
without any manual data capturing or annotation. We proved the effectiveness of our approach by visualizing the result and comparing
it to real video footage, and further proved that the dataset is usefuland effective as a training dataset for computer vision by developing a fish counting system to support fish farms. We compared theresult of the computer vision estimation with the count conductedby human vision, and the difference in the results was only 8 fish.
Our model automated the fish counting process and can reduce theburden of fish farm workers. Furthermore, it reduces the chance of
bodily injury to the fish, which can result from fish being exposed
to fresh air and fish rubbing against the nets.
Our fish simulation with biological and ecological details has
further potential to improve an animation pipeline. Boids [Reynolds
and Casterlin 1979] has been the standard approach for fish and birds
animation. However, the resulting animation misses several details
in the fish behavioral model, including the reactive behavior toenvironmental changes such as water temperature, light intensity,and occasional hovering behavior, which should occur in somepercentage of the fish in the fish cage because of their internal state.
The incorporation of the temperature and light effect, sensing range,and swimming speeds proportional to body lengths in our model
made the resulting animation more realistic. We plan to incorporate
more from biology and ecology, including biomimetic sensing withvision, hearing, smell, and the lateral line system, as well as otherbehavioral models such as mating and eating. We will further extend
the realism of the environment by introducing water currents that
influence the fish swimming behavior. This animation framework
based on biological, ecological, and environmental components
should, in principle, improve the visual quality of the animation andFoids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets •207:11(a) Sequence of frames from a captured video from a bottom view around 10am in real scene. The details of the experimental setting are explained inAppendix A(b) Sequence of frames from an animation generated by a Boids simulation from a bottom view at 10am. A boundary avoidance rule was added as an
extra component to conduct a fair comparison with Foids. The observed fish behavioral pattern was too monotone when compared to the real scene.

(c) Sequence of frames from an animation generated by the Foids simulation from a bottom view at 10am. Temperature effects, light effects, a morebiologically determined social distance, and swimming speed based on body length, rather than uniformly and artificially defined parameters worked
effectively to generate a more realistic schooling pattern of the fish, which resembled the real scene.
Fig. 8. Comparison of the scenes captured from a bottom view around 10am: (a) Real scene (b) Boids Simulation and (c) Foids Simulation.

can potentially automate the production pipeline by only requiringhigh-level scripting rather than frame-by-frame control.
We have focused on salmonids in a fish farm environment in thispaper. However, the system can be applied to other fish species,
including tuna, yellow tail, and carp, which are often farmed for the
purpose of food sustainability. The same simulation system of theenvironment can be directly applied to this extension, and the basic
simulation pipeline for the fish behavioral model can be reused.
The biological and ecological characteristic of different fishes varies
among species, and those variables have to be adjusted; however,this can be achieved fairly easily by referencing papers in marine
biology.
Because of the complexity of water simulations with fluid dynamics, we excluded the simulation of water and water currents fromour current pipeline. This approach worked in our favor as we had
to create a large dataset quickly. However, further improvementof the water simulation can be beneficial by further improving thequality of the animations. Although there are competing theories
about the effect of water currents on fish behavior, they are known
to have some effect. In a caged environment, salmonids are known
to intentionally choose to swim against a strong current to train
their physical strength from time to time. It is likely that it affects
the circling direction of the fish to some extent, although the topic
is not yet well studied. We plan to utilize our simulation platform as
a testing bed to investigate unproven hypotheses in marine biology.

Another limitation is a potential visual discrepancy between our
simulation and a real scene. We conducted a qualitative experimentwith captured videos; however, the quantity of the samples was insufficient. We plan to conduct further qualitative analysis with more
samples. Our simulation scene is rendered with Unity HDRP (HighDefinition Rendering Pipeline) and the color is currently determinedby custom programmable shaders. More accurate physically based
rendering is one of our future works.
Our fish counting model worked well with the video data we
captured; however, there is a chance that the accuracy drops whenocclusion is severe. We plan to work on an improved computer visionmodel utilizing our proposed dataset, which detects and tracks eachfish ID between frames, and should be able to avoid the potential
miscount problem due to occlusion.

ACKNOWLEDGMENTS
We would like to thank Kazuto Suda, Tomohiro Yoshida, Tadateru
Itoh, Tadayuki Tone, and Gaku Yasui from SoftBank Corp., Tadao
Turumi, Shiori Sone, and Shinichiro Ide from Nosan Corporationand Hirofumi Tokai from Maruhiro Suisan for conducting the experiments at the fish farm; Alfin Nurhalim for developing the fishcounting model; and Wuyue Lu for help with the underwater simulation from NeuralX Inc.
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

207:12 •Yuko Ishiwaka, Masaki Nakada, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah Gross, and Ryosuke Mizutani(a) 6am(b) 9am(c) noonFig. 10. An example dataset generated by our synthetic data platform. We
randomly changed the variables for the scene based on real-world physicalconstraints, and generated a 3-second animation for each scene with various
environments and fish behaviors.

(d) 3pm(e) 6pm(f) 9pm
Fig. 9. Sequence of frames from an animation at different times of day.
These simulated scenes were captured at 3 hour intervals from 6am - 9pm.
The difference of the scenes due to the time changes were easily observed.

ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

Fig. 11. An example of a 2D bounding box dataset generated by our synthetic
data platform. We randomly changed the variables for the scene based onreal-world physical constraints, and generated a 3-second animation foreach scene with various environments and fish behaviors. The 2D boundingbox was computed by projecting the 3D fish model to screen space, andstoring the pixel coordinates in CSV format.

Foids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets •(a) Frame 24(b) Frame 115(c) Frame 162

207:13(d) Frame 203

Fig. 12. Example images of the fish counting system. The captured video was recorded by a camera with fisheye wide FOV lens placed at the bottom of the
cage. Then, the data was fed to our fish counting pipeline, and the total number of fish in the cage was estimated automatically.

REFERENCES
John P Abraham, M Baringer, NL Bindoff, T Boyer, LJ Cheng, JA Church, JL Conroy, CM
Domingues, JT Fasullo, J Gilson, et al. 2013. A review of global ocean temperatureobservations: Implications for ocean heat content estimates and climate change.
Reviews of Geophysics 51, 3 (2013), 450–483.
University of Western Australia (UWA) Australian Institute of Marine Science (AIMS)
and Curtin University. 2019. OzFish Dataset - Machine learning dataset for Baited
Remote Underwater Video Stations. (2019). https://doi.org/10.25845/5e28f062c5097
Horst Bleckmann. 2004. 3-D-orientation with the octavolateralis system. Journal of
Physiology-Paris 98, 1-3 (2004), 53–65.
Alexey Bochkovskiy, Chien-Yao Wang, and Hong-Yuan Mark Liao. 2020. Yolov4: Optimal speed and accuracy of object detection. arXiv preprint arXiv:2004.10934 (2020).
Alisha A Brown, Marcia L Spetch, and Peter L Hurd. 2007. Growing in circles: Rearing
environment alters spatial navigation in fish. Psychological Science 18, 7 (2007),569–573.
Iain D. Couzin, Christos C. Ioannou, Güven Demirel, Thilo Gross, Colin J. Torney, Andrew Hartnett, Larissa Conradt, Simon A. Levin, and Naomi E. Leonard.
2011. Uninformed Individuals Promote Democratic Consensus in Animal Groups.
Science 334, 6062 (2011), 1578–1580. https://doi.org/10.1126/science.1210280
arXiv:https://science.sciencemag.org/content/334/6062/1578.full.pdf
KF Cubitt, S Churchill, D Rowsell, DA Scruton, RS McKinley, et al. 2003. 3-dimensional
positioning of salmon in commercial sea cages: assessment of a tool for monitoring
behaviour. In Aquatic telemetry. Advances and applications. Proceedings of the fifth
Conference on Fish Telemetry held in Europe, Ustica, Italy. 25–33.
César Roberto de Souza, Adrien Gaidon, Yohann Cabon, and Antonio Manuel López
Peña. 2017. Procedural Generation of Videos to Train Deep Action Recognition
Networks. arXiv:1612.00881 [cs.CV]
Ellen M Ditria, Rod M Connolly, Eric L Jinks, and Sebastian Lopez-Marcano. 2021.
Annotated video footage for automated identification and counting of fish in unconstrained marine environments. https://doi.org/10.1594/PANGAEA.926930
Andrew Dittman and Thomas Quinn. 1996. Homing in Pacific salmon: mechanisms
and ecological basis. Journal of Experimental Biology 199, 1 (1996), 83–91.
Alexey Dosovitskiy, German Ros, Felipe Codevilla, Antonio Lopez, and Vladlen Koltun.
2017. CARLA: An Open Urban Driving Simulator. arXiv:1711.03938 [cs.LG]
Anders Fernö, Ingvar Huse, Jon-Erik Juell, and Åsmund Bjordal. 1995. Vertical distribution of Atlantic salmon (Salmo solar L.) in net pens: trade-off between surface lightavoidance and food attraction. Aquaculture 132, 3-4 (1995), 285–296.
Ole Folkedal, Lars Helge Stien, Jonatan Nilsson, Thomas Torgersen, Jan Erik Fosseidengen, and Frode Oppedal. 2012. Sea caged Atlantic salmon display size-dependent
swimming depth. Aquatic Living Resources 25, 2 (2012), 143–149.
Martin Føre, Tim Dempster, Jo Arve Alfredsen, Vegar Johansen, and David Johansson.
2009. Modelling of Atlantic salmon (Salmo salar L.) behaviour in sea-cages: A
Lagrangian approach. Aquaculture 288, 3-4 (2009), 196–204.
Saeed Ghorbani, Kimia Mahdaviani, Anne Thaler, Konrad Kording, Douglas James
Cook, Gunnar Blohm, and Nikolaus F. Troje. 2020. MoVi: A Large Multipurpose
Motion and Video Dataset. arXiv:2003.01888 [cs.CV]
Kaiming He, Georgia Gkioxari, Piotr Dollár, and Ross Girshick. 2017. Mask r-cnn. In
Proceedings of the IEEE international conference on computer vision. 2961–2969.
James E Herbert-Read, Andrea Perna, Richard P Mann, Timothy M Schaerf, David JT
Sumpter, and Ashley JW Ward. 2011. Inferring the rules of interaction of shoaling
fish. Proceedings of the National Academy of Sciences 108, 46 (2011), 18726–18731.
A.L. Hodgkin and A.F. Huxley. 1952. A quantitative description of membrane current
and its application to conduction and excitation in nerve. Journal of Physiology 117(1952), 500–544.
I Huse and JC Holm. 1993. Vertical distribution of Atlantic salmon (Salmo salar) as afunction of illumination. Journal of Fish Biology 43 (1993), 147–156.

Malthe Hvas, Ole Folkedal, and Frode Oppedal. 2021. Fish welfare in offshore salmon
aquaculture. Reviews in Aquaculture 13, 2 (2021), 836–852.
Hochul Hwang, Cheongjae Jang, Geonwoo Park, Junghyun Cho, and Ig-Jae Kim. 2021.
ElderSim: A Synthetic Data Generation Platform for Human Action Recognition
in Eldercare Applications. IEEE Access PP (01 2021), 1–1. https://doi.org/10.1109/
ACCESS.2021.3051842
Arne J Jensen, Bjørn O Johnsen, and Laila Saksgård. 1989. Temperature requirements in
Atlantic salmon (Salmo salar), brown trout (Salmo trutta), and Arctic char (Salvelinus
alpinus) from hatching to initial feeding compared with geographic distribution.
Canadian Journal of Fisheries and Aquatic Sciences 46, 5 (1989), 786–789.
David Johansson, Kari Ruohonen, Anders Kiessling, Frode Oppedal, Jan-Erik Stiansen,
Mark Kelly, and Jon-Erik Juell. 2006. Effect of environmental factors on swimming
depth preferences of Atlantic salmon (Salmo salar L.) and temporal and spatial
variations in oxygen levels in sea cages at a fjord site. Aquaculture 254, 1-4 (2006),
594–605.
Jon-Erik Juell. 1995. The behaviour of Atlantic salmon in relation to efficient cagerearing. Reviews in fish biology and fisheries 5, 3 (1995), 320–335.
Jon-Erik Juell and Håkan Westerberg. 1993. An ultrasonic telemetric system for automatic positioning of individual fish used to track Atlantic salmon (Salmo salar L.) ina sea cage. Aquacultural engineering 12, 1 (1993), 1–18.
Yael Katz, Kolbjørn Tunstrøm, Christos C. Ioannou, Cristián Huepe, and Iain D. Couzin.
2011. Inferring the structure and dynamics of interactions in schooling fish. Proceedings of the National Academy of Sciences 108, 46 (2011), 18720–18725. https://doi.org/
10.1073/pnas.1107583108 arXiv:https://www.pnas.org/content/108/46/18720.full.pdf
Yoshimi Kawai and Akiyoshi Wada. 2007. Diurnal sea surface temperature variationand its impact on the atmosphere and ocean: A review. Journal of oceanography 63,
5 (2007), 721–744.
Henri Korn and Donald S Faber. 2005. The Mauthner cell half a century later: aneurobiological model for decision-making? Neuron 47, 1 (July 2005), 13—28. https://doi.org/10.1016/j.neuron.2005.05.019
Jens Krause, Jean-Guy J Godin, and David Brown. 1996. Phenotypic variability within
and between fish shoals. Ecology 77, 5 (1996), 1586–1591.
CC LINDSEY. 1978. Form, function, and locomotory habits in fish. Fish Physiology VII(1978), 1–100. https://ci.nii.ac.jp/naid/10024970754/
Stefano Marras, Shaun S Killen, Jan Lindström, David J McKenzie, John F Steffensen,
and Paolo Domenici. 2015. Fish swimming in schools save energy regardless of
their spatial position. Behavioral ecology and sociobiology 69, 2 (2015), 219–226.
Ollie Matthews, Koki Ryu, and Tarun Srivastava. 2020. Creating a Large-scale Synthetic
Dataset for Human Activity Recognition. arXiv:2007.11118 [cs.CV]
Thomas H. Miller, Katie Clements, Sungwoo Ahn, Choongseok Park, Eoon
Hye Ji, and Fadi A. Issa. 2017.
Social Status–Dependent Shift in Neural Circuit Activation Affects Decision Making.
Journal of Neuroscience37, 8 (2017), 2137–2148.
https://doi.org/10.1523/JNEUROSCI.1548-16.2017
arXiv:https://www.jneurosci.org/content/37/8/2137.full.pdf
AVS Murty. 1969. A theoretical approach to the attenuation coefficient of light in sea
water. Indian Journal of Fisheries 16, 1&2 (1969), 151–155.
Gabrielle A Nevitt, Andrew H Dittman, Thomas P Quinn, and William J Moody. 1994.
Evidence for a peripheral olfactory memory in imprinted salmon. Proceedings of the
National Academy of Sciences 91, 10 (1994), 4288–4292.
Lucy Odling-Smee and Victoria A Braithwaite. 2003. The role of learning in fishorientation. Fish and Fisheries 4, 3 (2003), 235–246.
Frode Oppedal, Tim Dempster, and Lars H Stien. 2011. Environmental drivers of Atlantic
salmon behaviour in sea-cages: a review. Aquaculture 311, 1-4 (2011), 1–18.
DS Pavlov and AO Kasumyan. 2000. Patterns and mechanisms of schooling behavior
in fish: a review. Journal of Ichthyology 40, 2 (2000), S163.
Sahithi Podila and Ying Zhu. 2017a. Animating Escape Maneuvers for a School of Fish.
In Proceedings of the 21st ACM SIGGRAPH Symposium on Interactive 3D Graphics and

ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

207:14 •Yuko Ishiwaka, Masaki Nakada, Xiao S. Zeng, Michael Lee Eastman, Sho Kakazu, Sarah Gross, and Ryosuke MizutaniGames (San Francisco, California) (I3D ’17). Association for Computing Machinery,
New York, NY, USA, Article 18, 2 pages. https://doi.org/10.1145/3023368.3036845
Sahithi Podila and Ying Zhu. 2017b. Animating Multiple Escape Maneuvers for a
School of Fish. In Proceedings of Graphics Interface 2017 (Edmonton, Alberta) (GI2017). Canadian Human-Computer Communications Society / Société canadienne
du dialogue humain-machine, 140 – 147. https://doi.org/10.20380/GI2017.18
Bryan A. Reyes, Julie S. Pendergast, and Shin Yamazaki. 2008. Mammalian Peripheral Circadian Oscillators Are Temperature Compensated. Journal of Biological Rhythms 23, 1 (2008), 95–98. https://doi.org/10.1177/0748730407311855
arXiv:https://doi.org/10.1177/0748730407311855 PMID: 18258762.
Craig Reynolds. 1999. Steering Behaviors For Autonomous Characters.
Craig W Reynolds. 1987. Flocks, herds and schools: A distributed behavioral model.
In Proceedings of the 14th annual conference on Computer graphics and interactive
techniques. 25–34.
William Wallace Reynolds and Martha Elizabeth Casterlin. 1979. Behavioral thermoregulation and the “final preferendum” paradigm. American zoologist 19, 1 (1979),
211–224.
Alzayat Saleh, Issam H. Laradji, Dmitry A. Konovalov, Michael Bradley, David Vazquez,and Marcus Sheaves. 2020. A realistic fish-habitat dataset to evaluate algorithms forunderwater visual analysis. Scientific Reports 10, 1 (Sep 2020). https://doi.org/10.
1038/s41598-020-71639-x
Daiki Satoi, Mikihiro Hagiwara, Akira Uemoto, Hisanao Nakadai, and Junichi Hoshino.
2016. Unified Motion Planner for Fishes with Various Swimming Styles. ACM
Transactions on Graphics (Proc. SIGGRAPH) 35, 4 (2016). https://doi.org/10.1145/
2897824.2925977
Michael Sfakiotakis, David M Lane, and J Bruce C Davies. 1999. Review of fish swimming
modes for aquatic locomotion. IEEE Journal of oceanic engineering 24, 2 (1999), 237–
252.
Kingsley Stephens, Binh Pham, and Aster Wardhani. 2003. Modelling Fish Behaviour. In
Proceedings of the 1st International Conference on Computer Graphics and Interactive
Techniques in Australasia and South East Asia (Melbourne, Australia) (GRAPHITE’03). Association for Computing Machinery, New York, NY, USA, 71–78. https://doi.org/10.1145/604471.604488
AM Sutterlin, KJ Jokola, and B Holte. 1979. Swimming behavior of salmonid fish inocean pens. Journal of the Fisheries Board of Canada 36, 8 (1979), 948–954.
Penny Tarling, Mauricio Cantor, Albert Clapés, and Sergio Escalera. 2021. Deep learningwith self-supervision and uncertainty regularization to count fish in underwater
images. (2021). arXiv:2104.14964 [cs.CV]
Xiaoyuan Tu and Demetri Terzopoulos. 1994. Artificial Fishes: Physics, Locomotion,
Perception, Behavior. In Proceedings of the 21st Annual Conference on Computer
Graphics and Interactive Techniques (SIGGRAPH ’94). Association for Computing
Machinery, New York, NY, USA, 43–50. https://doi.org/10.1145/192161.192170
Gül Varol, Javier Romero, Xavier Martin, Naureen Mahmood, Michael J. Black, Ivan
Laptev, and Cordelia Schmid. 2017. Learning from Synthetic Humans. In CVPR.
C.A.G. Wiersma and K. Ikeda. 1964. Interneurons commanding swimmeret movements in the crayfish, Procambarus clarki (girard). Comparative Biochemistry andPhysiology 12, 4 (1964), 509–525. https://doi.org/10.1016/0010-406X(64)90153-7
Steven J Zottoli. 1978. Comparison of Mauthner cell size in teleosts. Journal ofComparative Neurology 178, 4 (1978), 741–757.

A

Fig. 15. Underwater light intensity (from 9:00am to 10:00am in March 2021)

Fig. 16. Video capturing devices placed on the side (left), and at the bottom(right) of cage

DATA COLLECTION AT A FISH FARMIn March 2021, we collected data for our simulation on a fish farm,
both at the ocean surface and underwater, including the temperatureand light intensity in the water, a sample of the salmons’ body sizes
and weights, and underwater video data. The fish farm is locatedat Onmaehama, Miyagi Prefecture, Japan (latitude 38.465493 andlongitude 141.480474), in the ocean. The fish cage is a cube with sidesof length 6m (Fig. 13), and coho salmons (Oncorhynchus kisutchare)
and trout salmons (Oncorhynchus mykiss) were being farmed ineach cage. The mesh size of the net is 30.3mm. The weather on the
day of the experiment was sunny, the temperature was 12◦ C, andthe wave height was 1m.

A.1

Fig. 13. A fish farming cage Fig. 14. Salmon body length measurement

Fish body measurements

The cage contained 570, 272 coho and trout salmons according toa manual human count respectively. Realistic size variations areimportant in our method; therefore, a sample of fish body measurements was taken. Three large, medium, and small salmons, as
ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.

estimated by a fish farmer, were caught and anesthetized. Aftermeasuring the weight, caudal body length, height, and width, the9 salmons were returned to the cage. The body sizes are shown intable 4.

A.2

Environmental data

Underwater temperature and illumination are used as inputs in our
simulation. Water temperature was measured every 1m with an SK
SATO SK1260 (Table 2). The light intensity on the surface of thesea was measured using a HOLDPEAK 881E digital light intensity
meter. To measure the underwater light intensity, we connected a
TSL25721 light intensity sensor module to a Raspberry Pi for logging
and placed it in a waterproof smartphone case. The light intensity
at the surface is shown in Table 3. The values at each time are theaverages of the measurements at each corner of the fish cage, andFig.15 shows the underwater light intensity measured at the sametime as the video recording.

Foids: Bio-Inspired Fish Simulation for Generating Synthetic Datasets •→Step 1. Pull the net of the fish cage
towards the measuring equipment

207:15→
Step 2. Gather the fish in one place

Step 3. Fill the measuring tank with afixed amount of seawater↓←
Step 6. Visually count the fish while
releasing them←
Step 5. Measure the weight of thefishesStep 4. Scoop up several fish with afishing net and put them into the tankFig. 17. Current fish counting process

A.3

Video Recordings

A KODAK 4KVR360 camera was chosen for underwater video
recording because it has a wide angle of view of 235 degrees infisheye mode. Video was captured at 24 fps at a 2880x2880 resolution. Each camera used at the side of the cage is placed in anunderwater housing and fixed horizontally to a PVC pipe at a depth
of 4m shown on the left side of Fig.16. The center camera used takevideos from bottom of the cage was placed at a depth of 6m (theright side of Fig.16). The videos were recorded twice for about one
hour each.

A.4

Fish counting at a fish farmThis section describes the actual process of fish counting in fish
farming (Fig.17).
(1) Pull the net of the fish cage towards the weight scale.
(2) Gather the fish in one place. At this time, bend the net so that
half of the fish are present and the other half can be released.
(3) Fill the measuring tank with a fixed amount of seawater andcalibrate the weight scale.
(4) Scoop up several fish with a fishing net and put them into
the tank.
(5) Measure the weight of the fishes.
(6) Visually count the fish while releasing them and take note of
the results.
(7) Return the fish cage net to its original position.
The counting process can injure the fish 1 . After counting the fish,
dislodged scales can often be seen floating on the surface. In addition,
1 Fish counting with human vision was not performed for this paper and we only used

the results of the current counting method. Nosan Corporation’s technical center selects
and implements test methods that minimize fish suffering as much as possible in fish
research.

Table 2. Water temperature at the fish cage (March 2021)

Depth (m)Temp (°C)

0
8.3

1
8.3

2
8.1

3
8.1

4
8.1

5
8.1

6
8.1

Table 3. The average of the light intensities at each corner of the fish
cage (March 2021)

Time
Light Intensity (lux)

10:00
54850

12:00
10654

16:00
5198

Table 4. Body sizes of coho salmons in the cage. ID = Fish ID, BL= Body Length, H = Height, W = Width, WT = Weight Left:Coho
Salmons, Right: Trout Salmons

ID
1
2
3
4
5
6
7
8
9

BL(cm)
34.7
42.5
35.3
44.8
34.6
44.2
33.2
38.7
25.5
39.3
32.3
39.7
24.6
35.4
28.7
33.6
28.1
38.3

H(cm)
8.5
14.7
9.2
13.2
8.9
13.3
7.9
11.2
5.8
11.8
8.8
11.2
5.3
8.9
6.6
10.5
6.5
10.2

W (cm)
4.5
7.8
4.7
8.5
4.8
7.5
4.2
6.3
2.9
6.2
3.9
6.3
2.8
4.5
3.2
4.9
3.4
5.3

WT (kg)
0.8
2.2
0.6
2.1
0.7
2.1
0.5
1.1
0.2
1.2
0.5
1.1
0.15 0.6
0.2
0.7
0.3
0.8

Av.

30.29

7.38

3.74

0.39

39.61

11.67

6.37

1.32

this method is only possible when the cage stocking density is low.
When the stocking density in the cage is high, there is no way to
directly count the fish.

ACM Trans. Graph., Vol. 40, No. 6, Article 207. Publication date: December 2021.