updated utils.py

Co-authored-by: Fangjun Kuang <csukuangfj@gmail.com>
This commit is contained in:
zr_jin 2024-10-21 12:33:28 +08:00 committed by GitHub
parent eb239cb634
commit edc4eb3372
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2287,7 +2287,7 @@ def time_warp(
return features return features
assert ( assert (
len(features.shape) == 3 len(features.shape) == 3
), "SpecAugment only supports batches of single-channel feature matrices." ), f"SpecAugment only supports batches of single-channel feature matrices. {features.shape}"
features = features.clone() features = features.clone()
if supervision_segments is None: if supervision_segments is None:
# No supervisions - apply spec augment to full feature matrices. # No supervisions - apply spec augment to full feature matrices.