Torchvision installed with pacman, present in /usr/include, absent from usr/lib/python/3.11/site-packages

Update: sorry, I found the problem … had to call
pacman -S python-torchvision
instead …

Now everything works fine.


I’ve been installing torch some time ago. No problemo, everything worked nicely.

I needed torchvision today: si I pacmaned it:
pacman -S torchvision
Once the installation was finished, I tried it :

print(f" torch version :{torch.__version__} ")
import torchvision

and got the following result :

Traceback (most recent call last):
  File "/home/ctamegara/codes/python/pytorch/", line 3, in <module>
    import torchvision
ModuleNotFoundError: No module named 'torchvision'

So I checked : torchvision is actually present in /usr/include but absent from usr/lib/python/3.11/site-packages.

So I think I missed something somewhere. Any help is appreciated.

OS: Manjaro Linux x86_64
Kernel: 6.5.13-7-MANJARO
DE: GNOME 45.4
CPU: Intel i7-8700
GPU: NVIDIA GeForce GT 720

You need to install the python module.

sudo pacman -S python-torchvision

This topic was automatically closed 36 hours after the last reply. New replies are no longer allowed.