[Past CI] 🔥 Leave Past CI failures in the past 🔥 (#20861)
* torch.jit._state * Fix past CI * Fix for perceiver * Fix REALM * Fix for Bloom * Fix for SwinMode * Fix for TrajectoryTransformerModel * Fix for test_wav2vec2_with_lm * make style Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
This commit is contained in:
@@ -70,6 +70,9 @@ if is_torch_available():
|
||||
_compute_mask_indices,
|
||||
_sample_negative_indices,
|
||||
)
|
||||
from transformers.pytorch_utils import is_torch_less_than_1_9
|
||||
else:
|
||||
is_torch_less_than_1_9 = True
|
||||
|
||||
|
||||
if is_torchaudio_available():
|
||||
@@ -1640,6 +1643,10 @@ class Wav2Vec2ModelIntegrationTest(unittest.TestCase):
|
||||
|
||||
@require_pyctcdecode
|
||||
@require_torchaudio
|
||||
@unittest.skipIf(
|
||||
is_torch_less_than_1_9,
|
||||
reason="`torchaudio.functional.resample` needs torchaudio >= 0.9 which requires torch >= 0.9",
|
||||
)
|
||||
def test_wav2vec2_with_lm(self):
|
||||
ds = load_dataset("common_voice", "es", split="test", streaming=True)
|
||||
sample = next(iter(ds))
|
||||
@@ -1664,6 +1671,10 @@ class Wav2Vec2ModelIntegrationTest(unittest.TestCase):
|
||||
|
||||
@require_pyctcdecode
|
||||
@require_torchaudio
|
||||
@unittest.skipIf(
|
||||
is_torch_less_than_1_9,
|
||||
reason="`torchaudio.functional.resample` needs torchaudio >= 0.9 which requires torch >= 0.9",
|
||||
)
|
||||
def test_wav2vec2_with_lm_pool(self):
|
||||
ds = load_dataset("common_voice", "es", split="test", streaming=True)
|
||||
sample = next(iter(ds))
|
||||
|
||||
Reference in New Issue
Block a user