and listify them

This commit is contained in:
James Betker 2022-10-10 12:13:49 -06:00
parent 3cf78e3c44
commit fce2c8f5db

View File

@ -304,7 +304,7 @@ class DiffusionTtsFlat(nn.Module):
assert precomputed_aligned_embeddings is not None or (aligned_conditioning is not None and conditioning_input is not None) assert precomputed_aligned_embeddings is not None or (aligned_conditioning is not None and conditioning_input is not None)
assert not (return_code_pred and precomputed_aligned_embeddings is not None) # These two are mutually exclusive. assert not (return_code_pred and precomputed_aligned_embeddings is not None) # These two are mutually exclusive.
unused_params = [self.mel_head.parameters()] unused_params = [list(self.mel_head.parameters())]
if conditioning_free: if conditioning_free:
code_emb = self.unconditioned_embedding.repeat(x.shape[0], 1, x.shape[-1]) code_emb = self.unconditioned_embedding.repeat(x.shape[0], 1, x.shape[-1])
unused_params.extend(list(self.code_converter.parameters()) + list(self.code_embedding.parameters())) unused_params.extend(list(self.code_converter.parameters()) + list(self.code_embedding.parameters()))