Skip to content

Commit

Permalink
[Fix] Fix torchaudio load params (#2582)
Browse files Browse the repository at this point in the history
filepath => uri
  • Loading branch information
pengzhendong authored Jul 24, 2024
1 parent 08b031b commit edf0655
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wenet/dataset/processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ def decode_wav(sample):
start_frame = int(sample['start'] * sample_rate)
end_frame = int(sample['end'] * sample_rate)
with io.BytesIO(wav_file) as file_obj:
waveform, _ = torchaudio.load(filepath=file_obj,
waveform, _ = torchaudio.load(file_obj,
num_frames=end_frame - start_frame,
frame_offset=start_frame)
else:
Expand Down

0 comments on commit edf0655

Please sign in to comment.