snirpo / node-vad Goto Github PK
View Code? Open in Web Editor NEWVoice activation detection library for NodeJS
License: MIT License
Voice activation detection library for NodeJS
License: MIT License
Hi,
When I try to install node-vad on MacOS, the following warning appeared.
npm i -s node-vad
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/complex_fft.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/ilbc_specific_functions.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/levinson_durbin.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/min_max_operations.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/randomization_functions.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/real_fft.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/resample.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/resample_48khz.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/resample_by_2.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/resample_by_2_internal.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/resample_fractional.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/spl_core.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/spl_init.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/splitting_filter.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/spl_sqrt.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/spl/spl_sqrt_floor.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/vad/vad_core.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/vad/vad_filterbank.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/vad/vad_gmm.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/vad/vad_sp.o
CC(target) Release/obj.target/webrtc_vad/vendor/webrtc_vad/vad/webrtc_vad.o
LIBTOOL-STATIC Release/webrtc_vad.a
CC(target) Release/obj.target/vad/src/simplevad.o
CXX(target) Release/obj.target/vad/src/vad_bindings.o
../src/vad_bindings.cc:60:19: warning: 'Call' is deprecated [-Wdeprecated-declarations]
callback->Call(2, argv); // callback(error, result)
^
../../nan/nan.h:1739:3: note: 'Call' has been explicitly marked deprecated here
NAN_DEPRECATED inline v8::Local<v8::Value>
^
../../nan/nan.h:104:40: note: expanded from macro 'NAN_DEPRECATED'
# define NAN_DEPRECATED __attribute__((deprecated))
^
1 warning generated.
Can you please take a look? Thanks.
I installed package vie npm. while trying to run my app getting this error.
my package.json is like
{
"private": true, "scripts": { "dev": "npm run development", "development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js", "watch": "npm run development -- --watch", "watch-poll": "npm run watch -- --watch-poll", "hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js", "prod": "npm run production", "production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --no-progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js" }, "devDependencies": { "axios": "^0.19", "cross-env": "^7.0", "laravel-mix": "^5.0.1", "lodash": "^4.17.13", "resolve-url-loader": "^3.1.0", "sass": "^1.15.2", "sass-loader": "^8.0.0", "vue-template-compiler": "^2.6.11" }, "dependencies": { "bindings": "^1.5.0", "fs": "0.0.1-security", "nan": "^2.14.0", "node-vad": "^1.1.4", "util-promisifyall": "^1.0.6", "voice-activity-detection": "0.0.5", "vue": "^2.1.10" }
}
I tried to run code chunk is in https://npm.runkit.com/node-vad but its also gives same error. is there any solution for this situation?
Hello @Snirpo,
Thanks for the awesome work on the VAD project, I am trying to access the VOICE event in the createStream.
The following code works, but I want to send the buffer to the transcriber only when there is a speech not on Silence.
vadStreamPipe.on("data", (buffer) => {
transcriber.sendAudio(buffer.audioData);
});
I want to send audio only when VOICE is there.
vadStreamPipe.on('VOICE',(buffer)=>{
transcriber.sendAudio(buffer.audioData);
});
Something like the above should work. I have tried it but not working.
When i try to install node-vad, the error is raised. Thanks.
OS : osx 10.14(Mojave)
bindings.o
"v8::Value::ToInt32(v8::Localv8::Context) const", referenced from:
vad::vadAlloc_(Nan::FunctionCallbackInfov8::Value const&) in vad_bindings.o
vad::(anonymous namespace)::VADWorker::HandleOKCallback() in vad_bindings.o
"v8::External::Value() const", referenced from:
Nan::imp::FunctionCallbackWrapper(v8::FunctionCallbackInfov8::Value const&) in vad_bindings.o
"_node_module_register", referenced from:
_register_vad() in vad_bindings.o
"uv_default_loop", referenced from:
vad::vadProcessAudioBuffer(Nan::FunctionCallbackInfov8::Value const&) in vad_bindings.o
"uv_queue_work", referenced from:
vad::vadProcessAudioBuffer(Nan::FunctionCallbackInfov8::Value const&) in vad_bindings.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [Release/vad.node] Error 1
gyp ERR! build error
gyp ERR! stack Error: make
failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/Users/test/.nvm/versions/node/v8.9.4/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:262:23)
gyp ERR! stack at emitTwo (events.js:126:13)
gyp ERR! stack at ChildProcess.emit (events.js:214:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
gyp ERR! System Darwin 18.0.0
gyp ERR! command "/Users/test/.nvm/versions/node/v8.9.4/bin/node" "/Users/test/.nvm/versions/node/v8.9.4/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/test/nodetest/node_modules/node-vad
gyp ERR! node -v v8.9.4
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN [email protected] requires a peer of grunt@~0.4.1 but none is installed. You must install peer dependencies yourself.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.