When it reaches line 771 (kernel_old_init), it prints the error at XRT level and also the Logic error:
LogicError: <pyopencl._cl._ErrorRecord object at 0x7fe00f186340> Then I kept stepping through the code. It goes back to getattr in L436 and gives the Logic error in that function. Here is the pdb trace: -> getattr(prg, "_source", None) (Pdb) s --Call-- > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(434)__getattr__() -> def __getattr__(self, attr): (Pdb) > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(435)__getattr__() -> try: (Pdb) > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(436)__getattr__() -> knl = Kernel(self, attr) (Pdb) --Call-- > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(767)kernel_init() -> def kernel_init(self, prg, name): (Pdb) > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(768)kernel_init() -> if not isinstance(prg, _cl._Program): (Pdb) n > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(769)kernel_init() -> prg = prg._get_prg() (Pdb) > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(771)kernel_init() -> kernel_old_init(self, prg, name) (Pdb) s XRT build version: 2.3.0 Build hash: 8eb4d383b867c41879a3d462881d745d0a4f4671 Build date: 2019-07-23 10:44:38 Git branch: coverity_scan PID: 274671 UID: 31939 [Wed Jul 24 09:11:54 2019] HOST: xsjsagarwal EXE: /usr/bin/python2.7 [XRT] ERROR: kernel '_source' not found LogicError: <pyopenc...0f186340> > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(771)kernel_init() -> kernel_old_init(self, prg, name) (Pdb) --Return-- > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(771)kernel_init()->None -> kernel_old_init(self, prg, name) (Pdb) LogicError: <pyopenc...0f186340> > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(436)__getattr__() -> knl = Kernel(self, attr) (Pdb) import traceback; print "".join(traceback.format_exception_only(*__exception__)) LogicError: <pyopencl._cl._ErrorRecord object at 0x7fe00f186340> (Pdb) s > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(449)__getattr__() -> except LogicError: (Pdb) > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(450)__getattr__() -> raise AttributeError("'%s' was not found as a program " (Pdb) > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(451)__getattr__() -> "info attribute or as a kernel name" % attr) (Pdb) AttributeError: Attribut...l name",) > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(451)__getattr__() -> "info attribute or as a kernel name" % attr) (Pdb) import traceback; print "".join(traceback.format_exception_only(*__exception__)) AttributeError: '_source' was not found as a program info attribute or as a kernel name (Pdb) AttributeError: '_source' was not found as a program info attribute or as a kernel name (Pdb) s --Return-- > /usr/local/lib/python2.7/dist-packages/pyopencl/__init__.py(451)__getattr__()->None -> "info attribute or as a kernel name" % attr) (Pdb) n --Return-- > /scratch/sagarw/XRT/tests/demo.py(49)main()->None -> getattr(prg, "_source", None) (Pdb) --Return-- > /scratch/sagarw/XRT/tests/demo.py(52)<module>()->None -> main() (Pdb) Exception AttributeError: "'NoneType' object has no attribute 'path'" in <function _remove at 0x7fe047db66e0> ignored Best, Shivangi Agarwal On Wed, Jul 24, 2019 at 9:05 AM Andreas Kloeckner <li...@informa.tiker.net> wrote: > Shivangi Agarwal <shivangiagarwa...@gmail.com> writes: > > > Oh, it gives me this error: > > > > "AttributeError: '_source' was not found as a program info attribute or > as > > a kernel name" > > Does it print the entire execution stack before that? That's what I'm > interested in. > > Andreas >
_______________________________________________ PyOpenCL mailing list -- pyopencl@tiker.net To unsubscribe send an email to pyopencl-le...@tiker.net