huggingface / huggingface/optimum-executorch
ImportError: cannot import name 'Int8DynamicActivationIntxWeightConfig' from 'torchao.quantization.quant_api'
- Dominant language
- Python
- Stars
- 141
- Forks
- 48
- Avg merge
- 26m
- Merged PRs (30d)
- 2
Description
```
025-08-19 09:20:08.125345: E external/local_xla/xla/stream_executor/cuda/cuda_fft.cc:467] Unable to register cuFFT factory: Attempting to register factory for plugin cuFFT when one has already been registered
WARNING: All log messages before absl::InitializeLog() is called are written to STDERR
E0000 00:00:1755595208.384069 2643 cuda_dnn.cc:8579] Unable to register cuDNN factory: Attempting to register factory for plugin cuDNN when one has already been registered
E0000 00:00:1755595208.454020 2643 cuda_blas.cc:1407] Unable to register cuBLAS factory: Attempting to register factory for plugin cuBLAS when one has already been registered
W0000 00:00:1755595208.988350 2643 computation_placer.cc:177] computation placer already registered. Please check linkage and avoid linking the same target more than once.
W0000 00:00:1755595208.988389 2643 computation_placer.cc:177] computation placer already registered. Please check linkage and avoid linking the same target more than once.
W0000 00:00:1755595208.988393 2643 computation_placer.cc:177] computation placer already registered. Please check linkage and avoid linking the same target more than once.
W0000 00:00:1755595208.988400 2643 computation_placer.cc:177] computation placer already registered. Please check linkage and avoid linking the same target more than once.
2025-08-19 09:20:09.036179: I tensorflow/core/platform/cpu_feature_guard.cc:210] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX2 AVX512F FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
Multiple distributions found for package optimum. Picked distribution: optimum-executorch
config.json: 100% 861/861 [00:00<00:00, 3.97MB/s]
model.safetensors: 100% 269M/269M [00:03<00:00, 73.6MB/s]
Traceback (most recent call last):
File "/usr/local/bin/optimum-cli", line 8, in
sys.exit(main())
^^^^^^
File "/usr/local/lib/python3.11/dist-packages/optimum/commands/optimum_cli.py", line 208, in main
service.run()
File "/usr/local/lib/python3.11/dist-packages/optimum/commands/export/executorch.py", line 125, in run
main_export(
File "/usr/local/lib/python3.11/dist-packages/optimum/exporters/executorch/__main__.py", line 138, in main_export
model = task_func(model_name_or_path, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/optimum/exporters/executorch/tasks/causal_lm.py", line 135, in load_causal_lm_model
quantize_model_(eager_model, qlinear_config=qlinear_config, qembedding_config=qembedding_config)
File "/usr/local/lib/python3.11/dist-packages/optimum/exporters/executorch/quantization.py", line 28, in quantize_model_
from torchao.quantization.quant_api import (
ImportError: cannot import name 'Int8DynamicActivationIntxWeightConfig' from 'torchao.quantization.quant_api' (/usr/local/lib/python3.11/dist-packages/torchao/quantization/quant_api.py)
```
just tried running the example cli command, got this error
Contributor guide
Assessment
This issue has not been assessed yet.