Skip to content
Snippets Groups Projects
Commit ef0914cc authored by Kaushik Kulkarni's avatar Kaushik Kulkarni
Browse files

avoid using a method to grab the fake numpy namespace

parent e515c2d3
No related branches found
No related tags found
No related merge requests found
...@@ -55,15 +55,12 @@ class PytatoPyOpenCLArrayContext(ArrayContext): ...@@ -55,15 +55,12 @@ class PytatoPyOpenCLArrayContext(ArrayContext):
super().__init__() super().__init__()
self.queue = queue self.queue = queue
self.allocator = allocator self.allocator = allocator
self.np = self._get_fake_numpy_namespace() from arraycontext.impl.pytato.fake_numpy import PytatoFakeNumpyNamespace
self.np = PytatoFakeNumpyNamespace(self)
# unused, but necessary to keep the context alive # unused, but necessary to keep the context alive
self.context = self.queue.context self.context = self.queue.context
def _get_fake_numpy_namespace(self):
from arraycontext.impl.pytato.fake_numpy import PytatoFakeNumpyNamespace
return PytatoFakeNumpyNamespace(self)
# {{{ ArrayContext interface # {{{ ArrayContext interface
def clone(self): def clone(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment