audio

Detecting audio inside audio [Audio Recognition]

為{幸葍}努か 提交于 2020-07-10 07:26:43
问题 I need to build a software that does audio recognition from a small audio sample (A) inside other audio samples (B), and output how many times A appears inside the audio from B (if there is a match). What I have: A database with hundreds of audios Input: New audio Expected Output: A boolean if the input matches a sample from the database, and how many times appeared the input inside the matched audio (from the db). Any code, open source project, guides, books, videos, tutorial, etc... is

Detecting audio inside audio [Audio Recognition]

寵の児 提交于 2020-07-10 07:26:42
问题 I need to build a software that does audio recognition from a small audio sample (A) inside other audio samples (B), and output how many times A appears inside the audio from B (if there is a match). What I have: A database with hundreds of audios Input: New audio Expected Output: A boolean if the input matches a sample from the database, and how many times appeared the input inside the matched audio (from the db). Any code, open source project, guides, books, videos, tutorial, etc... is

MediaRecorder: Record from Multiple Microphones

江枫思渺然 提交于 2020-07-08 10:55:04
问题 I am currently using the MediaRecorder API to record audio inside an application. Is there a way to record from multiple input devices, say, two microphones? I can get a list of devices using mediaDevices.enumerateDevices() , as demonstrated here. Ideally, if possible, I would like to select two or more devices to be recorded. Is this possible? 回答1: this function will merge your tracks into one: function mix(audioContext, streams) { const dest = audioContext.createMediaStreamDestination();

Play and record sound using pyaudio simultaneously

爱⌒轻易说出口 提交于 2020-07-08 00:24:09
问题 I'm trying to create a program to talk back at once. I can't seem to get it to work. Some websites say use numpy arrays but I don't know how. import pyaudio import wave import time import multiprocessing as mp import pyaudio import numpy as np import sounddevice as sd fs = 44100 FORMAT = pyaudio.paInt16 CHANNELS = 2 RATE = 44100 CHUNK = 1024 audio = pyaudio.PyAudio() RECORD_SECONDS = 5 stream = audio.open(format=FORMAT, channels=CHANNELS, rate=RATE, input=True, frames_per_buffer=CHUNK)

Use bluetooth headset device as audio source in ffmpeg

£可爱£侵袭症+ 提交于 2020-07-07 13:02:46
问题 I want use a bluetooth headset as audio source for recording a video. I can use arecord -D bluetooth -f s16_le -c1 -r8000 command and pipe audio to ffmpeg. But this cause sync problems in audio and video. so i want to capture audio without arecord. How can i define bluetooth device as audio source in ffmpeg command? My asoundrc file: pcm.bluetooth { type bluetooth profile "auto" } ctl.bluetooth { type bluetooth } 回答1: After some digging in the ffmpeg docs, i managed to record sound via

How to concatenate multiple .wav files from a list in R?

你说的曾经没有我的故事 提交于 2020-07-06 12:34:09
问题 I have a list of .wav files my_list : library(seewave) library(tuneR) data(tico) audio <- tico freq <- 22050 breaks <- c(0,0.2,0.4,0.6,0.8) index <- 1:(length(breaks)-1) my_list<-lapply(index, function(i) audio[(breaks[i]*freq):(breaks[i+1]*freq)]) I want too combine all these files into 1 .wav file, but this doesn't work: index <- 1:length(breaks) allf =lapply(index, function(i) bind(my_list[[i]])) And this is too tedious to do since I have hundreds of multiple files to create: allf =bind(my

How to concatenate multiple .wav files from a list in R?

我是研究僧i 提交于 2020-07-06 12:34:07
问题 I have a list of .wav files my_list : library(seewave) library(tuneR) data(tico) audio <- tico freq <- 22050 breaks <- c(0,0.2,0.4,0.6,0.8) index <- 1:(length(breaks)-1) my_list<-lapply(index, function(i) audio[(breaks[i]*freq):(breaks[i+1]*freq)]) I want too combine all these files into 1 .wav file, but this doesn't work: index <- 1:length(breaks) allf =lapply(index, function(i) bind(my_list[[i]])) And this is too tedious to do since I have hundreds of multiple files to create: allf =bind(my

Sound Play / Stop / Pause

筅森魡賤 提交于 2020-07-06 10:05:35
问题 I'm developing a sound JavaScript library. I can play sound with below code. var soundPlayer = null; function playSound(){ soundPlayer = new Audio(soundName).play(); } How can I stop and pause this audio? When I try like this: soundPlayer.pause(); Or soundPlayer.stop(); But I get this error: Uncaught TypeError: soundPlayer.stop is not a function How can I do that? 回答1: If you change that: soundPlayer = new Audio(soundName).play(); To that: soundPlayer = new Audio(soundName); soundPlayer.play(

Sound Play / Stop / Pause

时光怂恿深爱的人放手 提交于 2020-07-06 10:04:29
问题 I'm developing a sound JavaScript library. I can play sound with below code. var soundPlayer = null; function playSound(){ soundPlayer = new Audio(soundName).play(); } How can I stop and pause this audio? When I try like this: soundPlayer.pause(); Or soundPlayer.stop(); But I get this error: Uncaught TypeError: soundPlayer.stop is not a function How can I do that? 回答1: If you change that: soundPlayer = new Audio(soundName).play(); To that: soundPlayer = new Audio(soundName); soundPlayer.play(

Sound Play / Stop / Pause

拥有回忆 提交于 2020-07-06 10:04:29
问题 I'm developing a sound JavaScript library. I can play sound with below code. var soundPlayer = null; function playSound(){ soundPlayer = new Audio(soundName).play(); } How can I stop and pause this audio? When I try like this: soundPlayer.pause(); Or soundPlayer.stop(); But I get this error: Uncaught TypeError: soundPlayer.stop is not a function How can I do that? 回答1: If you change that: soundPlayer = new Audio(soundName).play(); To that: soundPlayer = new Audio(soundName); soundPlayer.play(