How do I fix this import error? This is my first time installing the OCL backend for torch-cpu #94
Unanswered
degenerate-kun-69
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
running on RX5500m, installed
torch-2.5.0-cpu
as instructed on python 3.12 on ubuntu 24.04.1 LTS, OpenCL is installed for my gpu and it shows up in clinfo.the version im using is pytorch_ocl-0.2.0+torch2.5-cp312-none-linux_x86_64.whl, which i believe should be compatible
the piece of code giving me the error is
import torch import pandas as pd import numpy as np import matplotlib.pyplot as plt import pytorch_ocl print(torch.__version__) torch.randn(10,10,device='ocl:0')
<-this line here is throwing the errorError :
(TorchOCL) kokonut@GIGANIGGA:~/Documents/Programming/AI$ /home/kokonut/Documents/Programming/AI/TorchOCL/bin/python /home/kokonut/Documents/Programming/AI/test_ocl/test_ocl.py
Traceback (most recent call last):
File "/home/kokonut/Documents/Programming/AI/test_ocl/test_ocl.py", line 5, in
import pytorch_ocl
File "/home/kokonut/Documents/Programming/AI/TorchOCL/lib/python3.12/site-packages/pytorch_ocl/init.py", line 2, in
from .pt_ocl import *
ImportError: /home/kokonut/Documents/Programming/AI/TorchOCL/lib/python3.12/site-packages/pytorch_ocl/pt_ocl.so: undefined symbol: _ZN2at6native12cpu_fallbackERKN3c1014OperatorHandleEPSt6vectorINS1_6IValueESaIS6_EEbNS1_11DispatchKeyE
I am new to both ML and Linux, so any help would be greatly appreciated
Beta Was this translation helpful? Give feedback.
All reactions