Broke due to 'RecursionError: maximum recursion depth exceeded while calling a Python object' (and a temporary fix) (FIXED) #10
Replies: 3 comments 1 reply
-
OMG thx for the very informative bug report!!! I actually made a non-recursive version of the sentence splitter function just in case this was possible, I should be able to apply it tomorrow. This is rlly helpful and good to know tho! Extra info: The issue seems to be stemming from that I made it recursive thinking it would speed up the function but, nah this isn't worth it lol With the 250 limit thing yeah that means it might cut off the audio at the tts limit with your implementation if it's too long for the Xtts 'en' model to use |
Beta Was this translation helpful? Give feedback.
-
I applied my non recursive split_long_sentence function to the main branch, you should just be able to do a git pull then, Should fix any issues you were having with it before, worked on my end with my basic testing file, let me know if you run into any other issue or if your problem still persists! ALSO: also ill look more into your solution you made for the function cause you might be able to fix your warning: "[!] Warning: The text length exceeds the character limit of 250 for language 'en', this might cause truncated audio." by lowering the max_length value to 249 or 230 instead of 250 |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
So, when I would try to run the program, I would get this error whenever trying to generate audio for a particularly long sentence:
So it seems like something was going wrong with the 'split_long_sentence' function. I went and changed the code in gui_run.py from this:
to this:
And it seems to work now. In the terminal, I will still occasionally get this warning:
[!] Warning: The text length exceeds the character limit of 250 for language 'en', this might cause truncated audio.
But it doesn't seem to negatively impact the audio to any meaningful way. This fix was a lot of trial and error because, if it isn't already clear, I barely know what I'm doing, but I am sure the author would be able to see what was going wrong and patch it pretty easily.
Beta Was this translation helpful? Give feedback.
All reactions