Shark Spotters/PatternLab
Copyright Shark Spotters and PatternLab.
Shark Spotters/PatternLab
  • Using machine learning, scientists are teaching a computer to spot sharks and eventually predict their movements.
  • The low-cost automated shark spotting system will use fixed live-feed cameras at some of Africa’s most dangerous beaches.  
  • The scientists built a life-sized shark model named Joshua to test the machine. But they didn't expect a real shark to take notice.  

South African NPO Shark Spotters, the Institute for Communities and Wildlife in Southern Africa at UCT and a Swiss-based machine learning company will teach a computer to spot sharks to help prevent attacks on some of the country's most dangerous beaches.

It's an ambitious idea: building a low-cost automated shark spotting system that will pick up what a fatigued human eye could miss, from a fixed live-feed camera.

Shark Spotters/PatternLab
Shark Spotters lookout point above Fish Hoek. Copyright Shark Spotters and PatternLab.
Shark Spotters/PatternLab

It means an unlikely partnership between Shark Spotters and PatternLab, a Swiss company which specialises in data science and computer-aided vision. 

But where the Swiss team may lack experience in tracking sharks, they more than make up in tech.

Jay Caboz
Dr. Krzysztof Kryszczuk, a Pattern Recognition specialist from PatternLab
Jay Caboz

Dr. Krzysztof Kryszczuk, a senior pattern recognition specialist from PatternLab has a wealth of knowledge in teaching machines to track objects and behaviours.  

From a crowded room in the Save Our Seas Shark Education Centre in Kalk Bay, the kite-surfing tanned Kryszczuk gave a presentation showing a year’s worth of research that laid the groundwork for the project.  


To see if it was even possible, the team had to build a life-sized shark model named Joshua, that sank to the correct depth.  

Shark Spotters/PatternLab
Joshua the shark model. Copyright Shark Spotters and PatternLab.
Shark Spotters/PatternLab

“Sharks don't show up every day. So how do we build data? We need images and videos of sharks,” said Kryszczuk.  


Joshua was then taken to Fish Hoek bay, ceremoniously dumped into the Atlantic and then dragged around behind a speed boat at the ‘correct speed’ a shark would travel in the water.

Fixed cameras, located at a Shark Spotter lookout point, recorded the tests and began to teach the machine to pick up the appearance model of the 2-meter sized Joshua, which looks like a small blurry dot on screen.


What they didn't realise was a curious shark actually started to follow them. 

Shark Spotters/PatternLab
Copyright Shark Spotters and PatternLab.
Shark Spotters/PatternLab

We zoomed in for you. 


Because the scientists know the size of Joshua is accurate, the machine can be modelled to track similar moving sized dots from the lookout point. And because the footage can be divided into grids, the machine can pick up movement.

Shark Spotters/PatternLab
The AI can pick up movement by dividing the footage into grids. Copyright Shark Spotters and PatternLab.
Shark Spotters/PatternLab

Over time it will learn to differentiate between the pattern of a real shark versus something like a wad of kelp that drifts in with the tide.

Shark Spotters/PatternLab
Tracked movement of a shark against kelp. Copyright Shark Spotters and PatternLab.
Shark Spotters/PatternLab


The cameras aren’t intended to replace the hard work of real people, but rather will work alongside and upskill the spotters of the Shark Spotters programme.

They bring with them 15 years’ worth of knowledge and experience on shark behaviour with more than 2,500 successful shark-human preventions.

Their experience has proven to be vital to training the machine as they have the know-how to spot sharks under different weather conditions.  A bright sunny day might seem ideal for people to spot sharks, but on a camera its a different story competing with glare and luminosity for example. The ocean can also look completely different when its cloudy, or when the wind is blowing, which the machine will have to learn from scratch.  

“These were factors we didn’t know about, but to the spotters these factors were intuitively known,” said Kryszczuk.

Machine learning and fixed cameras are a much more cost-effective way of managing shark spotting than other forms of technology, said Sarah Waries CEO of Shark Spotters. They thought drones could work, but in order to do the same work as a machine, you would need to have a fleet of drones that can't fly when its windy.  

Jay Caboz
Sarah Waries CEO Shark Spotters.
Jay Caboz

Using this technology could also help Shark Spotters at other beaches. The current system is dependent on spotting stations being located high up on cliffs, so spotters can see into the water. A camera on a pole, could be a cheap easy solution, if it works out.

“We want it to be able to pick up a number of different marine animals. But this will require ‘training’ to be able to differentiate between sharks, whales, dolphins etc,” said Waries.

The research project will run for 2 years. The project is funded by the Eurostars programme, an international scheme that supports innovative projects led by research and development. In SA its funding is administered by the department of science and technology, and in Switzerland by Innosuisse.

According to the conditions of the funding, the project needs to be commercialised after three years.   

For more go to Business Insider South Africa.

Receive a single WhatsApp every morning with all our latest news: click here.

Also from Business Insider South Africa: