ONNX export and inference. Complete and tested implmentation.

This commit is contained in:
mush42
2023-09-24 01:57:35 +02:00
parent 2cd057187b
commit 1b204ed42c
6 changed files with 396 additions and 6 deletions

View File

@@ -116,7 +116,7 @@ class MatchaTTS(BaseLightningClass): # 🍵
w = torch.exp(logw) * x_mask
w_ceil = torch.ceil(w) * length_scale
y_lengths = torch.clamp_min(torch.sum(w_ceil, [1, 2]), 1).long()
y_max_length = int(y_lengths.max())
y_max_length = y_lengths.max()
y_max_length_ = fix_len_compatibility(y_max_length)
# Using obtained durations `w` construct alignment map `attn`