Beta/venv/lib/python3.12/site-packages/ctranslate2/models/__init__.py

19 lines
479 B
Python
Raw Permalink Normal View History

2026-02-06 22:23:20 +01:00
"""A collection of models which don't fit in the generic classes :class:`ctranslate2.Translator`
and :class:`ctranslate2.Generator`.
"""
try:
from ctranslate2._ext import (
Wav2Vec2,
Wav2Vec2Bert,
Whisper,
WhisperGenerationResult,
WhisperGenerationResultAsync,
)
except ImportError as e:
# Allow using the Python package without the compiled extension.
if "No module named" in str(e):
pass
else:
raise