array-api-jit 0.1.0__tar.gz → 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {array_api_jit-0.1.0/src/array_api_jit.egg-info → array_api_jit-1.0.0}/PKG-INFO +1 -3
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/pyproject.toml +2 -3
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/src/array_api_jit/__init__.py +1 -1
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/src/array_api_jit/_main.py +2 -4
- {array_api_jit-0.1.0 → array_api_jit-1.0.0/src/array_api_jit.egg-info}/PKG-INFO +1 -3
- array_api_jit-1.0.0/src/array_api_jit.egg-info/requires.txt +1 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/tests/test_main.py +1 -1
- array_api_jit-0.1.0/src/array_api_jit.egg-info/requires.txt +0 -3
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/LICENSE +0 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/README.md +0 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/setup.cfg +0 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/setup.py +0 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/src/array_api_jit/py.typed +0 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/src/array_api_jit.egg-info/SOURCES.txt +0 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/src/array_api_jit.egg-info/dependency_links.txt +0 -0
- {array_api_jit-0.1.0 → array_api_jit-1.0.0}/src/array_api_jit.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: array-api-jit
|
|
3
|
-
Version:
|
|
3
|
+
Version: 1.0.0
|
|
4
4
|
Summary: JIT decorator supporting multiple array API compatible libraries
|
|
5
5
|
Author-email: 34j <34j.95a2p@simplelogin.com>
|
|
6
6
|
License: MIT
|
|
@@ -21,8 +21,6 @@ Requires-Python: >=3.10
|
|
|
21
21
|
Description-Content-Type: text/markdown
|
|
22
22
|
License-File: LICENSE
|
|
23
23
|
Requires-Dist: array-api-compat>=1.11.2
|
|
24
|
-
Requires-Dist: cm-time>=0.1.2
|
|
25
|
-
Requires-Dist: frozendict>=2.4.6
|
|
26
24
|
Dynamic: license-file
|
|
27
25
|
|
|
28
26
|
# array API JIT
|
|
@@ -4,7 +4,7 @@ requires = [ "setuptools" ]
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "array-api-jit"
|
|
7
|
-
version = "
|
|
7
|
+
version = "1.0.0"
|
|
8
8
|
description = "JIT decorator supporting multiple array API compatible libraries"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
license = { text = "MIT" }
|
|
@@ -26,8 +26,6 @@ classifiers = [
|
|
|
26
26
|
|
|
27
27
|
dependencies = [
|
|
28
28
|
"array-api-compat>=1.11.2",
|
|
29
|
-
"cm-time>=0.1.2",
|
|
30
|
-
"frozendict>=2.4.6",
|
|
31
29
|
]
|
|
32
30
|
urls."Bug Tracker" = "https://github.com/34j/array-api-jit/issues"
|
|
33
31
|
urls.Changelog = "https://github.com/34j/array-api-jit/blob/main/CHANGELOG.md"
|
|
@@ -36,6 +34,7 @@ urls.repository = "https://github.com/34j/array-api-jit"
|
|
|
36
34
|
|
|
37
35
|
[dependency-groups]
|
|
38
36
|
dev = [
|
|
37
|
+
"cm-time>=0.1.2",
|
|
39
38
|
"jax>=0.4.30",
|
|
40
39
|
"numba>=0.60.0",
|
|
41
40
|
"pytest>=8,<9",
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
# https://github.com/search?q=gumerov+translation+language%3APython&type=code&l=Python
|
|
2
1
|
import importlib.util
|
|
3
2
|
import warnings
|
|
4
3
|
from collections.abc import Callable, Mapping, Sequence
|
|
@@ -14,7 +13,6 @@ from array_api_compat import (
|
|
|
14
13
|
is_numpy_namespace,
|
|
15
14
|
is_torch_namespace,
|
|
16
15
|
)
|
|
17
|
-
from frozendict import frozendict
|
|
18
16
|
|
|
19
17
|
if importlib.util.find_spec("numba"):
|
|
20
18
|
import numpy as np
|
|
@@ -123,8 +121,8 @@ def jit(
|
|
|
123
121
|
"""
|
|
124
122
|
|
|
125
123
|
def new_decorator(f: Callable[Pinner, Tinner]) -> Callable[Pinner, Tinner]:
|
|
126
|
-
decorator_args_ =
|
|
127
|
-
decorator_kwargs_ =
|
|
124
|
+
decorator_args_ = decorator_args or {}
|
|
125
|
+
decorator_kwargs_ = decorator_kwargs or {}
|
|
128
126
|
decorator_ = decorator or {}
|
|
129
127
|
|
|
130
128
|
@cache
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: array-api-jit
|
|
3
|
-
Version:
|
|
3
|
+
Version: 1.0.0
|
|
4
4
|
Summary: JIT decorator supporting multiple array API compatible libraries
|
|
5
5
|
Author-email: 34j <34j.95a2p@simplelogin.com>
|
|
6
6
|
License: MIT
|
|
@@ -21,8 +21,6 @@ Requires-Python: >=3.10
|
|
|
21
21
|
Description-Content-Type: text/markdown
|
|
22
22
|
License-File: LICENSE
|
|
23
23
|
Requires-Dist: array-api-compat>=1.11.2
|
|
24
|
-
Requires-Dist: cm-time>=0.1.2
|
|
25
|
-
Requires-Dist: frozendict>=2.4.6
|
|
26
24
|
Dynamic: license-file
|
|
27
25
|
|
|
28
26
|
# array API JIT
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
array-api-compat>=1.11.2
|
|
@@ -116,7 +116,7 @@ def test_jit(xp: Any) -> None:
|
|
|
116
116
|
print(xp.__name__, name)
|
|
117
117
|
for i in range(20):
|
|
118
118
|
with timer() as timer_:
|
|
119
|
-
x = xp.arange(1000000, dtype=xp.float32)
|
|
119
|
+
x = xp.arange(1000000, dtype=xp.float32) / 1000000
|
|
120
120
|
p = func(x, 10)
|
|
121
121
|
assert p.shape == (1000000, 10)
|
|
122
122
|
t[name] = timer_.elapsed
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|