No module named 'tosa' using executorch==0.7
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 5k
- Forks
- 1.2k
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 581
Description
🐛 Describe the bug
I installed executorch==0.7 by pip install, and when I run example code in https://docs.pytorch.org/executorch/stable/getting-started.html ,
from executorch.backends.arm.ethosu_partitioner import EthosUPartitioner
it raised the bug:
File ***/envs/vela/lib/python3.12/site-packages/executorch/backends/arm/tosa_quant_utils.py:23
21 from torch import Tensor
22 from torch.fx import Node
---> 23 from tosa.RoundingMode import RoundingMode # type: ignore
26 q_ops = (
27 exir_ops.edge.quantized_decomposed.quantize_per_tensor.default,
28 exir_ops.edge.quantized_decomposed.quantize_per_channel.default,
29 )
30 dq_ops = (
31 exir_ops.edge.quantized_decomposed.dequantize_per_tensor.default,
32 exir_ops.edge.quantized_decomposed.dequantize_per_channel.default,
33 )
ModuleNotFoundError: No module named 'tosa'
Versions
Versions of relevant libraries:
[pip3] executorch==0.7.0
[pip3] numpy==2.3.2
[pip3] nvidia-cublas-cu12==12.8.4.1
[pip3] nvidia-cuda-cupti-cu12==12.8.90
[pip3] nvidia-cuda-nvrtc-cu12==12.8.93
[pip3] nvidia-cuda-runtime-cu12==12.8.90
[pip3] nvidia-cudnn-cu12==9.10.2.21
[pip3] nvidia-cufft-cu12==11.3.3.83
[pip3] nvidia-curand-cu12==10.3.9.90
[pip3] nvidia-cusolver-cu12==11.7.3.90
[pip3] nvidia-cusparse-cu12==12.5.8.93
[pip3] nvidia-cusparselt-cu12==0.7.1
[pip3] nvidia-nccl-cu12==2.27.3
[pip3] nvidia-nvjitlink-cu12==12.8.93
[pip3] nvidia-nvtx-cu12==12.8.90
[pip3] torch==2.8.0
[pip3] torchao==0.12.0
[pip3] triton==3.4.0
[conda] executorch 0.7.0 pypi_0 pypi
[conda] numpy 2.3.2 pypi_0 pypi
[conda] nvidia-cublas-cu12 12.8.4.1 pypi_0 pypi
[conda] nvidia-cuda-cupti-cu12 12.8.90 pypi_0 pypi
[conda] nvidia-cuda-nvrtc-cu12 12.8.93 pypi_0 pypi
[conda] nvidia-cuda-runtime-cu12 12.8.90 pypi_0 pypi
[conda] nvidia-cudnn-cu12 9.10.2.21 pypi_0 pypi
[conda] nvidia-cufft-cu12 11.3.3.83 pypi_0 pypi
[conda] nvidia-curand-cu12 10.3.9.90 pypi_0 pypi
[conda] nvidia-cusolver-cu12 11.7.3.90 pypi_0 pypi
[conda] nvidia-cusparse-cu12 12.5.8.93 pypi_0 pypi
[conda] nvidia-cusparselt-cu12 0.7.1 pypi_0 pypi
[conda] nvidia-nccl-cu12 2.27.3 pypi_0 pypi
[conda] nvidia-nvjitlink-cu12 12.8.93 pypi_0 pypi
[conda] nvidia-nvtx-cu12 12.8.90 pypi_0 pypi
[conda] torch 2.8.0 pypi_0 pypi
[conda] torchao 0.12.0 pypi_0 pypi
[conda] triton 3.4.0 pypi_0 pypi
cc @digantdesai @freddan80 @per @zingo @oscarandersson8218
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the import in executorch/backends/arm/tosa_quant_utils.py and compare it with the installation instructions in the linked getting-started documentation. Verify how the tosa dependency is expected to be provided, then confirm that importing EthosUPartitioner after installing executorch==0.7 no longer raises ModuleNotFoundError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- embedded-iot, machine-learning
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100