diff --git a/optimum/bettertransformer/models/encoder_models.py b/optimum/bettertransformer/models/encoder_models.py index 20f7f4de50c..6a358100b2a 100644 --- a/optimum/bettertransformer/models/encoder_models.py +++ b/optimum/bettertransformer/models/encoder_models.py @@ -1833,7 +1833,7 @@ def forward(self, hidden_states, attention_mask, causal_attention_mask, output_a attention_mask, ) else: - NotImplementedError( + raise NotImplementedError( "Training and Autocast are not implemented for BetterTransformer + CLIP. Please open an issue." )