mirror of
https://github.com/fumiama/Retrieval-based-Voice-Conversion-WebUI.git
synced 2026-06-05 09:10:25 +08:00
chore(format): run black on dev (#54)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
3b7d7c6d1a
commit
cc11ad460d
@@ -36,10 +36,15 @@ class FCPE(F0Predictor):
|
||||
p_len = wav.shape[0] // self.hop_length
|
||||
if not torch.is_tensor(wav):
|
||||
wav = torch.from_numpy(wav)
|
||||
f0 = self.model.infer(
|
||||
wav.float().to(self.device).unsqueeze(0),
|
||||
sr=self.sampling_rate,
|
||||
decoder_mode="local_argmax",
|
||||
threshold=filter_radius,
|
||||
).squeeze().cpu().numpy()
|
||||
f0 = (
|
||||
self.model.infer(
|
||||
wav.float().to(self.device).unsqueeze(0),
|
||||
sr=self.sampling_rate,
|
||||
decoder_mode="local_argmax",
|
||||
threshold=filter_radius,
|
||||
)
|
||||
.squeeze()
|
||||
.cpu()
|
||||
.numpy()
|
||||
)
|
||||
return self._interpolate_f0(self._resize_f0(f0, p_len))[0]
|
||||
|
||||
Reference in New Issue
Block a user