Hi Ziqiao,

A System Error is a C-level error and suggests that python itself is having
a problem.
In short, this is never supposed to happen. I ran into the same problem
recently after
upgrading my installation of python from 3.7.3 to 3.7.4. Downgrading to
3.7.3 fixed it for me.

For me, this cropped up on MacOS (Mojave) running macports python and on
Ubuntu 18.04 running
the stock python installation.

All the best,

David

On Wed, Jul 17, 2019 at 11:03 AM Andreas Kloeckner <li...@marten.tiker.net>
wrote:

> Hi Ziqiao,
>
> Do you have numpy installed on your machine? That's the only thing I can
> think of as getting imported during import of the PyCUDA module. I've
> not seen that error before---have you tried building from source? Or
> using Christoph Gohlke's binaries?
>
> Andreas
>
> z...@asagi.waseda.jp writes:
> > I am Ziqiao, trying to use PyCUDA  to boost my calculation.
> > There were several attempts and I finally succeed to install PyCUDA.
> > However, when I try the sample code on the Wiki for a test, it shows
> this import error.
> >
> > --------------------
> > Traceback (most recent call last):
> >
> >   File "<ipython-input-1-44ade9f6a780>", line 1, in <module>
> >     runfile('D:/NICT/Python Scripts/PyCUDA_test.py',
> wdir='D:/NICT/Python Scripts')
> >
> >   File
> "C:\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py", line
> 880, in runfile
> >     execfile(filename, namespace)
> >
> >   File
> "C:\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py", line
> 102, in execfile
> >     exec(compile(f.read(), filename, 'exec'), namespace)
> >
> >   File "D:/NICT/Python Scripts/PyCUDA_test.py", line 9, in <module>
> >     import pycuda.driver as cuda
> >
> >   File "C:\Anaconda3\lib\site-packages\pycuda\driver.py", line 5, in
> <module>
> >     from pycuda._driver import *  # noqa
> >
> > SystemError: <class 'ImportError'> returned a result with an error set
> > --------------------
> >
> > My current environment is:
> > Win 10 64 bit
> > NVIDIA Quadro P1000 (with the latest driver)
> > Python 3.6.1 (with Anaconda 3 4.4.0)
> > Cuda 10.1.168_425.25 (for win 10)
> > Microsoft Visual Studio 14.0 (for the compiler)
> >
> > I used:
> > pycuda-2019.1+cuda101-cp36-cp36m-win_amd64.whl
> > pytools-2019.1.1-py2.py3-none-any.whl
> > to install PyCUDA and PyTools and they ended successfully.
> >
> > If anyone knows how to fix this, please let me know.
> > Thank you in advance!
> > _______________________________________________
> > PyCUDA mailing list -- pycuda@tiker.net
> > To unsubscribe send an email to pycuda-le...@tiker.net
> >
>
> _______________________________________________
> PyCUDA mailing list -- pycuda@tiker.net
> To unsubscribe send an email to pycuda-le...@tiker.net
>


-- 
David G. Grier <http://physics.nyu.edu/grierlab/> (he/his)
Department of of Physics <http://physics.nyu.edu/> and Center for Soft
Matter Research <http://csmr.as.nyu.edu/>
New York University <http://nyu.edu/>
726 Broadway, room 873, New York, NY 10003 <https://goo.gl/maps/Tbs7JatcW4y>
_______________________________________________
PyCUDA mailing list -- pycuda@tiker.net
To unsubscribe send an email to pycuda-le...@tiker.net

Reply via email to