Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Oct 8, 2023
1 parent c4f0eff commit 9c59816
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions data_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def get_audio_text_speaker_pair(self, audiopath_sid_text):

spec, wav = self.get_audio(audiopath)
sid = torch.LongTensor([int(self.spk_map[sid])])
emo = torch.FloatTensor(np.load(audiopath+".emo.npy"))
emo = torch.FloatTensor(np.load(audiopath + ".emo.npy"))
return (phones, spec, wav, sid, tone, language, bert, ja_bert, emo)

def get_audio(self, filename):
Expand Down Expand Up @@ -235,7 +235,7 @@ def __call__(self, batch):
bert_padded.zero_()
ja_bert_padded.zero_()
emo.zero_()

for i in range(len(ids_sorted_decreasing)):
row = batch[ids_sorted_decreasing[i]]

Expand Down Expand Up @@ -264,7 +264,7 @@ def __call__(self, batch):

ja_bert = row[7]
ja_bert_padded[i, :, : ja_bert.size(1)] = ja_bert

emo[i, :] = row[8]

return (
Expand Down

0 comments on commit 9c59816

Please sign in to comment.