Skip to content
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

Question about how cross-fade works in Realtime (may be bug?) #71

Open
Mojobones opened this issue Jul 15, 2024 · 2 comments
Open

Question about how cross-fade works in Realtime (may be bug?) #71

Mojobones opened this issue Jul 15, 2024 · 2 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@Mojobones
Copy link

Mojobones commented Jul 15, 2024

Hello! I have a question about how cross-fade works for the realtime GUI. This is more a question that could become either a feature request or a bug.

Theoretically it should be blending the chunks into each other, which should have nearly no latency hit as the slider would presumably control just how much of each chunk it uses.

But it seems like cross-fade adds latency to realtime output in a flat addition. Ex, I measured my latency for multiple crossfade values, and a cross-fade of .15 has almost exactly .1ms more latency than .05 which is quite a bit for real time communication.

But I was measuring from a cold start, as in i'd not be speaking, then speak, and measure the delta between my real voice and the changed voice.

So my question is: is cross-fade attempting to process silence? Like, will it append (length of crossfade) milliseconds at the beginning of a converted chunk so that it can cross-fade that silence into the output? If so, is this intended? If not, what causes the extra latency from crossfade?

Thank you so much for any insight! ❤️

@fumiama
Copy link
Owner

fumiama commented Jul 18, 2024

is cross-fade attempting to process silence

Yes.

If so, is this intended?

No. The original author do this just because it's easy to implement.

This is a problem. We can fix it later by detecting silence and not process it.

@fumiama fumiama added bug Something isn't working help wanted Extra attention is needed labels Jul 18, 2024
@TheTrustedComputer
Copy link

TheTrustedComputer commented Jul 19, 2024

I also noted that real-time inference uses the GPU even during silence; this honestly seems a waste of resources. I believe this is an opportunity for performance gains by implementing some sort of noise gate in a function handling "response threshold".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants