Skip to content

Commit

Permalink
Update 71-newfeatures.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbelgium authored Oct 14, 2024
1 parent 89e2992 commit b66f959
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion birdnet-pi/rootfs/etc/cont-init.d/71-newfeatures.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ bashio::log.info "Adding optional features"

if bashio::config.true "BAT_MODEL_ENABLED"; then
bashio::log.warning "... system will be modified to analyse bats!"
sed -i '/thread_queue_size/a\if [[ "$MODEL" == *"Bat"* ]]; then FFMPEG_PARAMS+="-vn -thread_queue_size 512 -i ${i} -map ${MAP_ID}:a:0 -t ${RECORDING_LENGTH} -acodec pcm_s16le -ac 2 file:${RECS_DIR}/StreamData/$(date "+%F")-birdnet-RTSP_${RTSP_STREAMS_STARTED_COUNT}-$(date "+%H:%M:%S").wav && python3 $HOME/BirdNET-Pi/scripts/bat_wav_translate.py ${RECS_DIR}/StreamData/$(date "+%F")-birdnet-RTSP_${RTSP_STREAMS_STARTED_COUNT}-$(date "+%H:%M:%S").wav"; fi' $HOME/*Pi/scripts/birdnet_recording.sh
sed -i '/thread_queue_size/a\ if [[ "$MODEL" == *"Bat"* ]]; then FFMPEG_PARAMS+="-vn -thread_queue_size 512 -i ${i} -map ${MAP_ID}:a:0 -t ${RECORDING_LENGTH} -acodec pcm_s16le -ac 2 file:${RECS_DIR}/StreamData/$(date "+%F")-birdnet-RTSP_${RTSP_STREAMS_STARTED_COUNT}-$(date "+%H:%M:%S").wav && python3 $HOME/BirdNET-Pi/scripts/bat_wav_translate.py ${RECS_DIR}/StreamData/$(date "+%F")-birdnet-RTSP_${RTSP_STREAMS_STARTED_COUNT}-$(date "+%H:%M:%S").wav"; fi' $HOME/*Pi/scripts/birdnet_recording.sh
echo "... installing wav translator"
cp /helpers/Bat_Model_BE_v1.py "$HOME"/BirdNET-Pi/scripts/bat_wav/translate.py
chmod +x "$HOME"/BirdNET-Pi/scripts/bat_wav_translate.py
Expand Down

0 comments on commit b66f959

Please sign in to comment.