Can Reinforcement Learning Save Whales Dying From Ship Strikes?

March 18, 2023

AI could help to avoid another whale sinking to the bottom of the ocean.

Thousands of whales die every year due to human activities. Besides commercial whaling, there is a spectrum of other ways we contribute to the loss of this magnificent animal. If we don’t act promptly, we are in great danger of whipping this majestic mammal altogether.

Climate change, pollution, bycatching, entanglement, and commercial whaling put a significant threat on the existence of these species. But there is another critical risk for whales' presence, which is the focus of this article.

Ship strikes.

According to the International whaling commission, there were about 1,200 whales killed between 2007 and 2016. Yet, many experts claim that there could be thousands killed every year.

Whales haven’t evolved to recognize the approaching vessel traffic. I guess no marine animal has. Also, today’s gigantic commercial vessels can not be stoped with sudden breaks.

Because whales sink to the bottom of the ocean when they die, most deaths go unreported.

But there is hope. Scientists and humanitarians have taken actions to reverse the losses. Their contribution is phenomenal. Now it’s our turn. Data scientists like you and me should play a vital role in conserving whales and other animals on this planet.

I’m writing this with a bit of hope that our suggestions could help a whale live its life to its entirety. If this is already happening, that’s great; share it with us in the comments. If not, help this article reach out to the right people.

How Technology Help saving whale population

A trivial solution is imposing a narrow traffic scheme. This method has been proven effective in many regions, including the Gulf of Panama.

The Gulf of Panama is home to thousands of humpback whales. A narrow shipping line scheme reduces the probability that a whale crossing vessel routes. Recent studies show that this technique has diminished whale deaths significantly.

Another straightforward way is to impose a speed limit on vessels. This procedure mitigates the risks of collisions and reduces the damage when they occur.

Yet, both these methods aren’t workable options in the open water. Most sea territories are still unprotected with little or no protocols.

The scientific community also has employed a range of AI-powered techniques. Here are some.

Google AI and National Oceanic and Atmospheric Administration (NOAA) on real-time orca detection.

Google AI created a model for detecting an endangered species of killer whales. It uses dozens of underwater microphones to detect orcas’ presence and alert officials.

Google trained the models with 1,800 hours of underwater audio recordings with 68,000 labels. It also conducts further studies to expand this to other kinds of whales and associate the sound signals with orca’s health conditions.

Project CETI by the government of Dominica and the national geographic society.

CETI is determined to deploy dozens of devices over the next five years. These devices could help us listen, interpret, and communicate back with sperm whales.

According to CETI, this is also the largest interspecies communication project ever.

CNN to recognize Humpback whale songs.

Another Google-NOAA collaborated project aims to recognize humpback whale songs. They used 187,000 hours of acoustic data to train the convolutional neural network. These deep neural networks distinguish between different themes using their frequency and patterns.

Analysis of this study showed drastic reductions of humpback whales in the Hawaiian region.

Canadian government’s right-whale detection.

This project uses computer vision to detect whales from aerial drone imagery. The project is aimed at protecting North Atlantic right whales from ship strikes.

This team has proven that deep learning can be used in the detection and classification of whales. They are also looking forward to scaling it up into more locations.

These efforts clearly show that we can have two-way communications with whales. If we could communicate, we could also drive them to a safe zone. That’s the key that caught my attention towards reinforcement learning.

To me, these individual researches seem like pieces of a giant puzzle. Reinforcement Learning could connect the unique components and may solve the riddle.

What is reinforcement learning?

In simple terms, reinforcement learning (RL) trains an agent to solve a complex problem by rewarding them for correct actions.

To understand it better, you could think of the agent as a child learning to swim. The child gets an instant reward for every action it performs in the pool. Gradually, the child knows what it needs to do to stay afloat, move forward, and breathe. Every time it drowns, the child learns what not to do. That’s learning to solve a problem by constantly interacting with the environment.

Yes, it’s a trial and error technique to solve complex problems.

What is reinforcement learning

In RL, the agent interacts with the environment by taking various actions. As a consequence, the state of the agent changes. These actions may or may not move the agent towards its goals. When it does, that’s the reward the agent gets. The agent’s primary objective is to maximize its total reward. But it needs to figure it out by exploring different alternatives.

RL differs from both supervised and unsupervised learning. The system needs to interact with the environment to collect data and train itself. Yet, it tries to find a generalized set of actions to solve the problem.

Recent success stories of OpenAI and Deempmind’s AlphaGo AI made RL a hot topic. A team of five artificial neural networks, named Open AI Five, defeated human players at Dota 2. It uses RL to teach itself how to play the game. Every day, the neural networks train themselves with some 180 years worth of games.

A fascinating point about RL is that its solutions are sometimes creative. Open AI, when playing Dota 2, occasionally sacrificed its team members to win the game. Although winning as a team is the chief goal, humans rarely take such ego-free strategies.

How could reinforcement learning stop whale-vessel collisions?

How could reinforcement learning stop whale-vessel collisions

This idea is not a tested hypothesis but one that’s worth discussing.

If whales respond to sonar signals, we can use it to send them warning signals as well. But we don’t know which frequency they would consider as potential threats. And there could be sound patterns as well. This is where RL comes for help.

A tiny device at the tip of the ship’s bow receives and sends sonar signals as our agent. Every time it sends an alert to the ocean, it may attract or chase away whales. The distant’s between the whales and the ship is the state of the agent. If the sonar detects any whales, that’s a punishment to the agent; in other words, a negative reward.

Detecting and warning whales in the open water

The agent’s primary goal is to maximize the total reward. In this whale warning case, it’s to chase away any whales in the path. Like Open AI being creative in Dota, the agent could be inventive in chasing whales. Who knows, the agent may gather all whales with one type of signal and then warn them all at once with a different kind.

Studies have proved that whales follow sonars. This sometimes even causes whales to beach themselves on the shore. The agent could change different frequencies and their patterns to communicate with whales. For example, a long beep of 233kHz followed by two clicks may mean something to whales. We don’t know what it is. The agent doesn’t know it either. But all the agent’s job is to find out if it chases the whales out from the path.

In addition to the apparent “saving whales” advantage, this could be an excellent solution for many reasons.

  1. Sailors don’t have a manual duty.
    When AI is employed in signaling whales to move out of their path, there is no manual effort involved. Also, because RL could adjust its signaling frequency, no hand-operated business was left for the sailors.
  2. Ships don’t have to change paths or slow down too much.
    Rules alone don’t work well on the open seas. Existing solutions demand route changes that cargo lines may perceive as uneconomical. Hence there is no guarantee the protocols will be followed correctly.
  3. Nobody wants to kill whales for fun; sailors neither.
    Even commercial whalers (Sorry to mention this disturbing act multiple times) may not like killing whales for sport.

The solution may sound straightforward. But as with any research, this has a bunch of complications we need to address.

  1. Can a sonar device produce the right frequency to drive whales out from its path?
    There is a hypothesis that says whales follow sonar signals of ships. But we lack research evidence to prove this. We don’t know which sonar frequency that whales follow and which ones they try to avoid.
  2. What is the long-term impact on whales and other sea animals?.
    Some research suggests that mobile phone signals causing severe damages to birds' routines and their health. Will our proposed solution leave any permanent trauma on these innocent animals? Are we causing more harm than good?
  3. Could the device’s signal is noticeable along with the noisy engines of the vessels?
    The noise of commercial vessels could be as high as 110 decibels. This much sound is enough to cause permanent hearing loss in humans. Could the whales pick the sonar amid colossal noise?
  4. Is it ethical?
    No, it’s not. The definition of ethics differs from person to person. For me, as an animal lover, my proposal seems unethical. We shouldn’t cross a whale's path. But the international trade doesn't seem to slow down. On this front, we have no other options.

Final thoughts

Whales are magnificent sea mammals that lived on this earth for millions of years. But due to human activities, it’s in the blink of extinction. When a species disappears in the food chain, it leads other animals to demise.

But scientists and environmentalists are making progress in combatting the phenomena. Like in any other arena, AI plays a crucial role in the conservation of whales as well.

Ship strikes are a terrifying cause that claims many whale lives. We discussed some of the ways data science help avoiding this is. And we’ve addressed a solution of using reinforcement learning to stop whales from crossing a vessel’s path.

This abstract idea is far from perfect. But everything needs to start somewhere. Perhaps, it’s here. Please share your thoughts and constructively criticize in the comments.

Thanks for spreading the good words. It could save a whale.

Did you like what you read? Consider subscribing to my email newsletter because I post more like this frequently.

Thanks for reading, friend! Say Hi to me on
LinkedIn, Twitter, and Medium.

How we work

Readers support The Analytics Club. We earn through display ads. Also, when you buy something we recommend, we may get an affiliate commission. But it never affects your price or what we pick.

Connect with us