Skip to content
This repository was archived by the owner on Jun 3, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions src/sparseml/transformers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
import transformers as _transformers

# triggers error if neuralmagic/transformers is not installed
_transformers.models.bert.modeling_bert.QATMatMul
assert _transformers.NM_INTEGRATED
_transformers_import_error = None
except Exception as _transformers_import_err:
_transformers_import_error = _transformers_import_err
Expand Down Expand Up @@ -101,11 +101,10 @@ def _check_transformers_install():
try:
import transformers as _transformers

_transformers.models.bert.modeling_bert.QATMatMul
assert _transformers.NM_INTEGRATED
except Exception:
_LOGGER.warning(
"transformers.models.bert.modeling_bert.QATMatMul not availalbe. the"
"neuralmagic fork of transformers may not be installed. it can be "
"the neuralmagic fork of transformers may not be installed. it can be "
"installed via "
f"`pip install {_NM_TRANSFORMERS_NIGHTLY}`"
)
Expand Down