-
Notifications
You must be signed in to change notification settings - Fork 232
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request] background noise cancelling #68
Comments
Exactly this! I would like to use this feature to mute my surroundings when I am working. So there would be no need to run any application. Just sample the microphone, do the noise-canceling, and feed results to my earphones. |
@gitowiec that's not possible, and i don't think that's what @mksaleem was asking for. You want active noise cancellation on your headphones, and (one of) the reason(s) you can't just do that in software on your PC is because it's simply too slow to work. The latency requirements for this are extreme. |
Thank you for such a quick response. I didn't know that modern PCs are too slow for such tasks. When I recall headphones with built-in noise cancelation they are small devices. Where is the computational power hiding in such small devices, I would ask. |
Hmmm but @mksaleem said "like noise from vacuum cleaner or kids playing" - that is why I connected it with ANC in headphones... |
As far as I know it's not that the processor itself is too slow. But the input doesn't go from your microphone magically into your processor. It needs to go through USB, the Kernel, etc. all of this introduces latency. By the time the inverted signal is back in your headphones, it's too late. But, I'm also not an expert on this, so if anyone proves me wrong, i'd be very happy. But this is why you need dedicated hardware in your earphones to do this. What the issue is talking about is using a secondary microphone to pick up the background noise and then denoise your primary microphone. If you place the secondary microphone farther away from your mouth, then your speech signal will be higher on your primary than on your secondary and you can to some degree cancel out the noise. This does not have such extreme latency requirements, because you are not constrained by physics to do all of this between the time the sound waves travel from the microphone to your ear. |
@ZurMaD this is litterally what noisetorch is doing. cleaning it up via AI. in realtime. but that's not what this issue is about. |
This is actually was I was originally talking about and you understood me correctly. I hope it's possible and hopefully will see it soon. I have tried Krisp in Windows with discord and in my opinion Noisetorch works better. |
Am I correct with assumption that when it will be implemented, it will efficiently cancel voice sound from other people in the room, for example? |
There is a difference between the two scenarios with capturing your environment:
The headphones scenario doesn't handle latency as well. You need to produce sound that cancels out the sound you're targeting, but if you can't minimize that latency window enough, you'd not be able to act in time. An analogy might be if you put on VR headset, where an object such as a ball is thrown to you at a random interval, and you need to catch the ball. If you are relying on visual cue and that visual cue is delayed too much, you will miss each time due to the latency difference not being small enough for you to react. Whereas with the microphone to capture your voice for chat, if latency were problematic you might have some desync from video (if any), which can look off; otherwise for a a voice only call it's far less likely to be noticeable.
This was mostly answered already. The device doesn't need to run a generic operating system either, the hardware often has firmware (similar to software) or leverages hardware specialized for a task (like your GPU for graphics, Wifi/bluetooth radios for wireless), often a DSP for handling the audio and presumably for the recent AI based models, some small NPU. Basically, the product is optimized/tailored for what it does best. Much like how a GPU vs CPU excel at different tasks. FWIW, I am not too knowledgeable about audio. I do not know what the required latency target is for pulling off noise cancellation effectively. Pipewire does have an echo cancellation plug-in apparently (although I've heard it's not perfect) which should perform this functionality with the two mics AFAIK. You can probably try set that up to check how it compares from a mic and to headphones?
I haven't tried it but the impression I get is it may help minimize it but not to expect too much. |
Hi
I am not sure if it possible. I would like to give an idea about cancelling background noise using secondary mic. Many gamers use headsets with microphone next to their mouth while having another mic either build into the Web camera or a laptop. I was wondering is its possible to cancel out background noise using the sample from secondary mic in realtime like noise from vacuum cleaner or kids playing etc.
The text was updated successfully, but these errors were encountered: