Memory leak in prepare_dataset() when using phonemizing using espeak (included temporary solution) #218
Labels
No Label
bug
duplicate
enhancement
help wanted
insufficient info
invalid
news
not a bug
question
wontfix
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: mrq/ai-voice-cloning#218
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
When creating a dataset from already generated whisper.json I noticed ram usage kept rising, so much so that it was using 50GB of pagefile.
Apparently calling phonemize a lot of times using espeak is very expensive. This is because it initializes the espeak backend each time the function is called.
I fixed this by going into phonemize.py in my venv and keeping a global variable for the espeak backend, see below. This also has the side effect of making the process A LOT faster. On my 29h dataset this would've taken hours, now it takes minutes.
Also really appreciate all the work you have done here and how well documented it is. When using a finetuned model, this is pretty much as good as elevenlabs.
I swear I've already committed a fix for it. It might actually only live in mrq/vall-e but I'll double check.
Nope, seems I didn't. I backported my wrapper from it instead of relying on brandishing a fork with it (or injecting override functions).
Should be fixed in commit
99387920e1
(should, I haven't tested it yet).