From 5ddb2e69c78625925cbb1848baa7cd8c7379ea43 Mon Sep 17 00:00:00 2001 From: Kaushik Kulkarni <kaushikcfd@gmail.com> Date: Tue, 29 Jun 2021 08:36:54 -0500 Subject: [PATCH] adds motivation for pytato-based array contexts in docs --- arraycontext/impl/pytato/__init__.py | 15 ++++++++++++++- doc/array_context.rst | 4 ++-- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/arraycontext/impl/pytato/__init__.py b/arraycontext/impl/pytato/__init__.py index 8080395..23bf708 100644 --- a/arraycontext/impl/pytato/__init__.py +++ b/arraycontext/impl/pytato/__init__.py @@ -1,7 +1,20 @@ """ .. currentmodule:: arraycontext + +A :mod:`pytato`-based array context defers the evaluation of an array until its +frozen. The execution contexts for the evaluations are specific to an +:class:`~arraycontext.ArrayContext` type. For ex. +:class:`~arraycontext.PytatoPyOpenCLArrayContext` uses :mod:`pyopencl` to +JIT-compile and execute the array expressions. + +Following :mod:`pytato`-based array context are provided: + .. autoclass:: PytatoPyOpenCLArrayContext + +Compiling a python callable +^^^^^^^^^^^^^^^^^^^^^^^^^^^ + .. automodule:: arraycontext.impl.pytato.compile """ __copyright__ = """ @@ -37,7 +50,7 @@ from pytools.tag import Tag class PytatoPyOpenCLArrayContext(ArrayContext): """ A :class:`ArrayContext` that uses :mod:`pytato` data types to represent - the DOF arrays targeting OpenCL for offloading operations. + the arrays targeting OpenCL for offloading operations. .. attribute:: queue diff --git a/doc/array_context.rst b/doc/array_context.rst index 7c8b581..7a12dfb 100644 --- a/doc/array_context.rst +++ b/doc/array_context.rst @@ -14,7 +14,7 @@ Array context based on :mod:`pyopencl.array` .. automodule:: arraycontext.impl.pyopencl -Array context based on :mod:`pytato` ------------------------------------- +Lazy/Deferred evaluation array context based on :mod:`pytato` +------------------------------------------------------------- .. automodule:: arraycontext.impl.pytato -- GitLab