Spaces:
Running
Running
speed improvements and documentation
Browse files
InferenceInterfaces/ControllableInterface.py
CHANGED
@@ -68,12 +68,9 @@ class ControllableInterface:
|
|
68 |
return_plot_as_filepath=False,
|
69 |
prosody_creativity=prosody_creativity,
|
70 |
loudness_in_db=loudness_in_db,
|
71 |
-
pitch=pitch,
|
72 |
-
energy=energy,
|
73 |
-
durations=durations)
|
74 |
-
print(pitch.shape)
|
75 |
-
print(energy.shape)
|
76 |
-
print(durations.shape)
|
77 |
wavs.append(wav)
|
78 |
wav = sum(wavs) / len(wavs)
|
79 |
else:
|
|
|
68 |
return_plot_as_filepath=False,
|
69 |
prosody_creativity=prosody_creativity,
|
70 |
loudness_in_db=loudness_in_db,
|
71 |
+
pitch=pitch.unsqueeze(0) if pitch is not None else pitch,
|
72 |
+
energy=energy.unsqueeze(0) if energy is not None else energy,
|
73 |
+
durations=durations.unsqueeze(0) if durations is not None else durations)
|
|
|
|
|
|
|
74 |
wavs.append(wav)
|
75 |
wav = sum(wavs) / len(wavs)
|
76 |
else:
|