tortoise-tts icon indicating copy to clipboard operation
tortoise-tts copied to clipboard

Alignmnent algorithm error

Open damianr13 opened this issue 2 years ago • 2 comments
trafficstars

Hello,

I was playing with voice clonning and I generated the following error:

AssertionError: Something went wrong with the alignment algorithm. I've dumped a file, 'alignment_debug.pth' toyour current working directory. Please report this along with the file so it can get fixed.

Here is the `alignment_debug.pth' file that got generated. alignment_debug.pth.zip

damianr13 avatar Jan 29 '23 12:01 damianr13

got the same error. repeatedly. both in colab and in an AWS Sagemaker.

Generating autoregressive samples..
100%|██████████| 16/16 [00:46<00:00,  2.88s/it]
Computing best candidates using CLVP and CVVP
100%|██████████| 16/16 [00:05<00:00,  2.78it/s]
Transforming autoregressive outputs into audio..
100%|██████████| 200/200 [00:12<00:00, 15.45it/s]
---------------------------------------------------------------------------
AssertionError                            Traceback (most recent call last)
[<ipython-input-33-e7f80cdb9586>](https://localhost:8080/#) in <module>
      1 # Generate speech with the custotm voice.
      2 voice_samples, conditioning_latents = load_voice(CUSTOM_VOICE_NAME)
----> 3 gen = tts.tts_with_preset(text, voice_samples=voice_samples, conditioning_latents=conditioning_latents, 
      4                           preset=preset)
      5 torchaudio.save(f'generated-{CUSTOM_VOICE_NAME}.wav', gen.squeeze(0).cpu(), 24000)

5 frames
[/content/tortoise-tts/tortoise/utils/wav2vec_alignment.py](https://localhost:8080/#) in align(self, audio, expected_text, audio_sample_rate)
    103         if not (len(expected_tokens) == 0 and len(alignments) == len(expected_text)):
    104             torch.save([audio, expected_text], 'alignment_debug.pth')
--> 105             assert False, "Something went wrong with the alignment algorithm. I've dumped a file, 'alignment_debug.pth' to" \
    106                           "your current working directory. Please report this along with the file so it can get fixed."
    107 

AssertionError: Something went wrong with the alignment algorithm. I've dumped a file, 'alignment_debug.pth' toyour current working directory. Please report this along with the file so it can get fixed.

gedefet avatar Feb 02 '23 13:02 gedefet

It looks like the message is related to a problem with a PyTorch tensor and its storage. The message mentions the functions _utils_rebuild_tensor_v2 and torch.FloatStorage, which suggest that the issue is related to a float tensor in PyTorch.

The message also mentions the term "alignment", which could suggest that the problem is related to memory alignment or data alignment issues in the code.

I would recommend checking the documentation and forums for the project or library you are using to see if there are any related issues or solutions that have been reported before

s-b-repo avatar Feb 03 '23 02:02 s-b-repo