Skip to content

Commit

Permalink
Merge pull request #872 from IAHispano/formatter/main
Browse files Browse the repository at this point in the history
chore(format): run black on main
  • Loading branch information
blaisewf authored Nov 14, 2024
2 parents 76bef85 + baa6169 commit 30741b0
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions rvc/train/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -441,8 +441,11 @@ def run(
# get the first sample as reference for tensorboard evaluation
if os.path.isfile(os.path.join("logs", "reference", f"ref{sample_rate}.wav")):
import numpy as np
phone = np.load(os.path.join("logs", "reference", f"ref{sample_rate}_feats.npy"))
#expanding x2 to match pitch size

phone = np.load(
os.path.join("logs", "reference", f"ref{sample_rate}_feats.npy")
)
# expanding x2 to match pitch size
phone = np.repeat(phone, 2, axis=0)
phone = torch.FloatTensor(phone).unsqueeze(0).to(device)
phone_lengths = torch.LongTensor(phone.size(0)).to(device)
Expand All @@ -458,7 +461,7 @@ def run(
phone_lengths,
pitch if pitch_guidance else None,
pitchf if pitch_guidance else None,
sid
sid,
)
else:
for info in train_loader:
Expand Down

0 comments on commit 30741b0

Please sign in to comment.