Internship report by Trek Hopton

The second in a series of reports by AusOcean summer interns.

Hello, my name is Trek. I’m a computer science graduate from The University of Adelaide and I have been working for AusOcean as an intern over this summer. That's a picture of me before a dive (more on that later).

I have spent most of my time developing software written in Go for the processing of audio, which is to be recorded from our oceans. Most of my work was done to achieve an optimal small audio data size so that we are not unnecessarily using up bandwidth or data storage in the cloud.

My first task was to add the ability for our software to convert audio from stereo to mono, effectively halving the data size. The process requires simply decoding the audio format (PCM) and removing all the samples that belong to the second channel and then encoding back to PCM. This was a good project to start on because it was a simple addition to existing code, this means I was able to familiarise myself with the code style and development process used at AusOcean.

Next I started working on a way to achieve a low sample rate of 8 kHz instead of the initial standard 44.1 kHz. Initially I tried to record at 8 kHz directly from a sound card however I ran into firmware issues so we switched to a cheaper USB sound card that records at 48 kHz. This means the audio must be downsampled in software, which is usually achieved by applying a low-pass filter and then decimating. The filtering proved to be difficult because there are no libraries written in Go that implement filters, so a moving average was used to approximate a low-pass filter. Then the decimation process simply keeps one out of every 6 samples.

My last and largest task was to implement audio compression. After a fair bit of research and experimentation, I found that there aren’t many options for audio compression written in Go. So I decided to implement a technique called Adaptive Differential Pulse Code Modulation (ADPCM) which isn’t as space saving as some complex compression algorithms, such as MP3, but still can achieve compression by a factor of 4 and is relatively simple.

For a week in mid December and for another in February I sailed with our trusty skipper Alan (AusOcean’s founder) and the AusOcean crew to the north coast of Kangaroo Island to test some technology and to research Smith Bay and the surrounding region. I was able to scuba dive with the marine biologists to help them conduct surveys of the seafloor and I also bought along my underwater camera to take some footage and photos of the pristine underwater environment and its inhabitants.

I really couldn’t have wished for a better internship. I thoroughly enjoyed myself on our expeditions, I learned a lot about Golang, audio processing, command line tools, version control, and I gained experience working with teams and using real world software development processes. I love that I was able to apply my skills to a real project that I believe will benefit something I’m passionate about, our oceans.

Posted by Trek Hopton