-
Notifications
You must be signed in to change notification settings - Fork 0
/
__init__.py
57 lines (45 loc) · 1.93 KB
/
__init__.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
"""This module is designed to seamlessly integrate with Taichi's
Ahead-of-Time (AOT) compilation capabilities, enabling users to leverage the
performance benefits of precompiled Taichi kernels.
Key Features:
- **AOT Compilation Support:** AOT-Taichi-Pybind facilitates the compilation
of Taichi kernels ahead of runtime, optimizing performance by eliminating
the need for just-in-time compilation during execution.
- **Seamless Python Integration:** The module ensures smooth
interoperability between Python and Taichi, allowing users to harness the
power of Taichi's C-API directly from their Python scripts.
- **Efficient Kernel Launching:** Users can launch Taichi kernels with the
provided Python bindings, passing runtime, kernel, and arguments seamlessly.
The module ensures that the provided arguments match the expected count and
types defined in the source code.
"""
from .c_api import *
from .interfaces import *
__all__ = [
# aliases
'TiBool', 'TiFlags',
# definitions
'TI_FALSE', 'TI_TRUE', 'TI_MAX_ARCH_COUNT', 'TI_NULL_HANDLE',
# enumerations
'TiError', 'TiArch', 'TiCapability', 'TiDataType', 'TiArgumentType',
'TiMemoryUsageFlags', 'TiImageUsageFlags', 'TiImageDimension',
'TiImageLayout', 'TiFormat', 'TiFilter', 'TiAddressMode',
# handles
'TiRuntime', 'TiAotModule', 'TiMemory', 'TiImage',
'TiKernel', 'TiComputeGraph', 'TiSampler',
# structures
'TiCapabilityLevelInfo', 'TiMemoryAllocateInfo', 'TiMemorySlice',
'TiNdShape', 'TiNdArray', 'TiImageOffset', 'TiImageExtent',
'TiImageAllocateInfo', 'TiImageSlice', 'TiSamplerCreateInfo',
'TiTexture', 'TiScalarValue', 'TiScalar', 'TiTensorValue',
'TiTensorValueWithLength', 'TiTensor', 'TiArgumentValue',
'TiArgument', 'TiNamedArgument',
# interfaces
'AotModule',
'ComputeGraph',
'Kernel',
'KernelArgument',
'Memory',
'Runtime',
'Sampler',
]