Hi, I have some code that runs fine as a standalone routine; however, I want to incorporate it as part of a web service using CherryPy as the hosting framework. When I try and call it from a client, I get:
[31/Aug/2011:21:56:38] HTTP Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/6.0.0/lib/python2.6/site-packages/cherrypy/_cprequest.py", line 606, in respond cherrypy.response.body = self.handler() File "/Library/Frameworks/Python.framework/Versions/6.0.0/lib/python2.6/site-packages/cherrypy/_cpdispatch.py", line 25, in __call__ return self.callable(*self.args, **self.kwargs) File "tscs.py", line 124, in POST response = self._analyze(data, kwargs) File "tscs.py", line 83, in _analyze row.append(self.stats[statid]['method'](data[id])) File "/Users/mjg/Projects/python/kiss/statistics.py", line 268, in gpuls lsp = Culsp() File "/Users/mjg/Projects/python/kiss/culsp.py", line 146, in __init__ mod = compiler.SourceModule(kernel_code) File "/Library/Frameworks/Python.framework/Versions/6.0.0/lib/python2.6/site-packages/pycuda-2011.1-py2.6-macosx-10.5-i386.egg/pycuda/compiler.py", line 271, in __init__ arch, code, cache_dir, include_dirs) File "/Library/Frameworks/Python.framework/Versions/6.0.0/lib/python2.6/site-packages/pycuda-2011.1-py2.6-macosx-10.5-i386.egg/pycuda/compiler.py", line 218, in compile arch = "sm_%d%d" % Context.get_device().compute_capability() LogicError: cuCtxGetDevice failed: invalid context Any ideas? I'm running CUDA 4.0 and PyCUDA 2011.1.2. Cheers, Matthew _______________________________________________ PyCUDA mailing list PyCUDA@tiker.net http://lists.tiker.net/listinfo/pycuda