amsehili / auditok

An audio/acoustic activity detection and audio segmentation tool
MIT License
732 stars 94 forks source link

Errors running auditok #4

Closed Simpler1 closed 8 years ago

Simpler1 commented 8 years ago

I'm on Linux Mint 17.2.

When I try to run "auditok", I get the following messages:

~/git_projects/auditok $ auditok
ALSA lib pcm_dsnoop.c:618:(snd_pcm_dsnoop_open) unable to open slave
ALSA lib pcm_dmix.c:1022:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
bt_audio_service_open: connect() failed: Connection refused (111)
bt_audio_service_open: connect() failed: Connection refused (111)
bt_audio_service_open: connect() failed: Connection refused (111)
bt_audio_service_open: connect() failed: Connection refused (111)
ALSA lib pcm_dmix.c:1022:(snd_pcm_dmix_open) unable to open slave
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
1 0.00 5.00
2 5.00 10.00
3 10.00 15.00
4 15.00 20.00
^C5 20.00 20.60

Should I be concerned about any of these messages? It doesn't seem to be detecting any sound. It just outputs automatically every 5 seconds.

Any suggestions would be appreciated.

Thanks.

amsehili commented 8 years ago

Just ignore those messages, there isn't an easy way to get rid of them (follow this link to find out more about them).

Also you can redirect standard error to /dev/null (auditok [OPTIONS] 2> /dev/null)

It's detecting the whole input signal as an audio event (as chunks of 5 seconds because default value of -m is 5). This is because default value of energy threshold is too low for what you microphone is recording as silence. Use a higher valuer for energy (option -e) and/or reduce the input volume of the microphone from your system's settings.

If you have matplotlib installed, you can plot the signal and the energy threshold:

auditok -e 55 -M 7 -p

This will acquire 7 seconds of data and plot signal, threshold and detections once it's done.