MycroftAI / mimic-recording-studio

Mimic Recording Studio is a Docker-based application you can install to record voice samples, which can then be trained into a TTS voice with Mimic2
Apache License 2.0
493 stars 111 forks source link

Disable autoGainControl, echoCancellation and noiseSuppression #86

Closed kksteini closed 2 years ago

kksteini commented 2 years ago

Description

I was having issues with recording audio, it seems that a lot of the clips had dips or muffled sounding audio. I want the clips to retain their clarity and uniformity. Audio processing should much rather take place afterwards rather than "in browser".

After some debugging it turns out that the navigator.getUserMedia created a mediaRecorder with these settings enabled by default.

Type of PR

Testing

This was an issue for me on windows and linux, on firefox and chrome, on two different audiocards. Switching back and forth with the new constraints object was consistent with a fix.

Documentation

https://www.w3.org/TR/mediacapture-streams/#def-constraint-echoCancellation

CLA

To protect you, the project, and those who choose to use Mycroft technologies in systems they build, we ask all contributors to sign a Contributor License Agreement.

This agreement clarifies that you are granting a license to the Mycroft Project to freely use your work. Additionally, it establishes that you retain the ownership of your contributed code and intellectual property. As the owner, you are free to use your code in other work, obtain patents, or do anything else you choose with it.

If you haven't already signed the agreement and been added to our public Contributors repo then please head to https://mycroft.ai/cla to initiate the signing process.

krisgesling commented 2 years ago

Hey, thanks heaps for this - I definitely agree that we want to keep recordings in as raw a format as possible.

We could make these configurable at some point if someone did want to turn something on. But for professional recordings the browser should effectively be a dumb endpoint (from an audio perspective).

Regarding the CLA - I know it may seem like a small contribution however to protect yourself, the project, and users of Mycroft technologies we require a Contributor Licensing Agreement (CLA) before accepting any contributions to a Mycroft repository. This agreement makes it crystal clear that along with your code you are offering a license to use it within the confines of this project. You retain ownership of the code, this is just a license.

It might seem overkill on small PR's like this one, however it greatly simplifies our processes to have a blanket rule for all contributions. I hope you understand.

On the plus side - you will also be added to our list of excellent human beings!

Please visit https://mycroft.ai/cla to initiate this one-time signing.

Thanks again!

kksteini commented 2 years ago

Alright, CLA signed.