3.7 KiB
I've tested lots of settings by running 2 versions of my HA birdnet-pi addon in parallel using the same rtsp feed, and comparing impact of parameters. My conclusions aren't universal, as it seems to be highly dependent on the region and type of mic used. For example, the old model seems to be better in Australia, while the new one better in Europe.
Microphone considerations
The critical element is the microphone quality : a Boya By-lm 40 or clippy EM272 (with a very good aux-usb converter) is key to improve the quality of detections. Here is some example tests I did (whole threads are really interesting also): https://github.com/mcguirepr89/BirdNET-Pi/discussions/39#discussioncomment-9706951 https://github.com/mcguirepr89/BirdNET-Pi/discussions/1092#discussioncomment-9706191
My recommendation :
- Best entry system (< 50€) : Boya By-lm40 (30€) + deadcat (10 €)
- Best middle end system (< 150 €) : Clippy EM272 (55€) + Rode AI micro trrs to usb (70€) + Rycote deadcat (27€)
- Best high end system (<300 €) : Clippy EM272 XLR (85€) or LOM Ucho Pro (75€) + Focusrite Scarlet 2i2 4th Gen (200€) + Rycote/Bubblebee deadcat
App settings recommendation
- Model
- Version : 6k_v2,4 (performs better in Europe at least, the 6k performs better in Australia)
- Species range model : v1 (uncheck v2.4 ; seems more robust in Europe)
- Species occurence threshold : 0,001 (was 0,00015 using v2.4 ; use the Species List Tester to check the correct value for you)
- Audio settings
- Default
- Channel : 1 (doesn't really matter as analysis is made on mono signal ; 1 allows decreased saved audio size but seems to give slightly messed up spectrograms in my experience)
- Recording Length : 18 (that's because I use an overlap of 0,5 ; so it analysis 0-3s ; 2,5-5,5s ; 5-8s ; 7,5-10,5 ; 10-13 ; 12,5-15,5 ; 15-18)
- Extraction Length : 9s (could be 6, but I like to hear my birds :-))
- Audio format : mp3 (why bother with something else)
- Birdnet-lite settings
- Overlap : 0,5s
- Minimum confidence : 0,7
- Sigmoid sensitivity : 1,25 (I've tried 1,00 but it gave much more false positives ; as decreasing this value increases sensitivity)
Set RTSP server
On your desktop
Download imager Install raspbian lite 64
With ssh
sudo apt-get update sudo apt-get apt-get dist-upgrade
Optional : install Focusrite driver
apt-get install make linux-headers-$(uname -r)`) curl -LO https://github.com/geoffreybennett/scarlett-gen2/releases/download/v6.9-v1.3/snd-usb-audio-kmod-6.6-v1.3.tar.gz tar -xzf snd-usb-audio-kmod-6.6-v1.3.tar.gz cd snd-usb-audio-kmod-6.6-v1.3 KSRCDIR=/lib/modules/$(uname -r)/build make -j4 -C $KSRCDIR M=$(pwd) clean make -j4 -C $KSRCDIR M=$(pwd) sudo make -j4 -C $KSRCDIR M=$(pwd) INSTALL_MOD_DIR=updates/snd-usb-audio modules_install sudo depmod sudo reboot dmesg | grep -A 5 -B 5 -i focusrite
Install RTSP server
sudo apt-get install -y micro ffmpeg lsof sudo -s cd /root && wget -c https://github.com/bluenviron/mediamtx/releases/download/v1.8.3/mediamtx_v1.8.3_linux_arm64v8.tar.gz -O - | sudo tar -xz
List audio devices
arecord -l
Check audio device parameters. Example :
arecord -D hw:1,0 --dump-hw-params
Add startup script
sudo nano startmic.sh
#!/bin/bash
echo "Starting birdmic"
# Disable gigabit ethernet
sudo ethtool -s eth0 speed 100 duplex full autoneg on
# Start rtsp server
./mediamtx & true
# Create rtsp feed
sleep 5
ffmpeg -nostdin -f alsa -acodec pcm_s24le -ac 2 -ar 48000 -i hw:1,0 -f rtsp -acodec pcm_s16le rtsp://localhost:8554/birdmic -rtsp_transport tcp || true & true
# Set microphone volume
sleep 5
amixer -c 1 sset Mic 71%