xbarray 0.0.1a3__py3-none-any.whl → 0.0.1a4__py3-none-any.whl

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.

Potentially problematic release.


This version of xbarray might be problematic. Click here for more details.

@@ -1,5 +1,6 @@
1
1
  from typing import Any, Union, Callable
2
2
  from array_api_typing.typing_compat import ArrayAPINamespace as CompatNamespace, ArrayAPIArray as CompatArray, ArrayAPIDType as CompatDType
3
+ import array_api_compat
3
4
 
4
5
  __all__ = [
5
6
  "get_abbreviate_array_function",
@@ -19,7 +20,7 @@ def get_abbreviate_array_function(
19
20
  Or, if some dimensions are the same, abbreviates to a smaller array (but with the same number of dimensions).
20
21
  """
21
22
  abbr_array = array
22
- idx = backend.zeros(1, dtype=default_integer_dtype, device=backend.device(abbr_array))
23
+ idx = backend.zeros(1, dtype=default_integer_dtype, device=array_api_compat.device(abbr_array))
23
24
  for dim_i in range(len(array.shape)):
24
25
  first_elem = backend.take(abbr_array, idx, axis=dim_i)
25
26
  if backend.all(abbr_array == first_elem):
@@ -1,7 +1,5 @@
1
1
  import jax.numpy
2
2
 
3
- simplified_name = "jax"
4
-
5
3
  if hasattr(jax.numpy, "__array_api_version__"):
6
4
  compat_module = jax.numpy
7
5
  from jax.numpy import *
@@ -11,6 +9,8 @@ else:
11
9
 
12
10
  from array_api_compat.common._helpers import *
13
11
 
12
+ simplified_name = "jax"
13
+
14
14
  # Import and bind all functions from array_api_extra before exposing them
15
15
  import array_api_extra
16
16
  from functools import partial
@@ -1,4 +1,5 @@
1
1
  from array_api_compat.numpy import *
2
+ from array_api_compat.common._helpers import *
2
3
 
3
4
  simplified_name = "numpy"
4
5
 
@@ -1,4 +1,5 @@
1
1
  from array_api_compat.torch import *
2
+ from array_api_compat.common._helpers import *
2
3
 
3
4
  simplified_name = "pytorch"
4
5
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: xbarray
3
- Version: 0.0.1a3
3
+ Version: 0.0.1a4
4
4
  Summary: Cross-backend Python array library based on the Array API Standard.
5
5
  Requires-Python: >=3.10
6
6
  License-File: LICENSE
@@ -16,16 +16,16 @@ xbarray/__init__.py,sha256=k4Ipp7IoODqHWZ-eeBhcU7Ch8FudF8rag6KbeIurrgY,45
16
16
  xbarray/jax.py,sha256=3DHAFsWvfurCI0H6loqx4LtmBov9KbIxeHGmwLKrdh4,344
17
17
  xbarray/numpy.py,sha256=8thyuJZlm0MJXGx6YWlgxV9ASG-In9jn-pwUFFk7iB4,358
18
18
  xbarray/pytorch.py,sha256=NEKlF_QoiOQl0T-aP_CkUxJ3HgFJEm0hmLy9v5I7qAo,372
19
- xbarray/_src/implementations/_common/implementations.py,sha256=FyZaQZcVdSnH6CUA1LVbUJAK-EAlkz2fDfOOuVyku6Y,2655
20
- xbarray/_src/implementations/jax/__init__.py,sha256=pkQASOOePuTel32zaSmsNIc9FqL_8Ix0P4NDXMqhupE,827
19
+ xbarray/_src/implementations/_common/implementations.py,sha256=ba6fyoHMrawrrjTULSqt073-aMw7abqFWh5YnzeOHMU,2688
20
+ xbarray/_src/implementations/jax/__init__.py,sha256=fZMtXujTLhfHofWJzeMtsOuNhUYSZzCEj06RulT4RqQ,827
21
21
  xbarray/_src/implementations/jax/_extra.py,sha256=2akggZTP2xIXe5AdVs4rNk8yCJOpTJX8rlv94SY4HJA,2525
22
22
  xbarray/_src/implementations/jax/_typing.py,sha256=U9BUxHNEjFB0LHF1KMrFLbh6E5kVvpAF8bZUbLNf25E,278
23
23
  xbarray/_src/implementations/jax/random.py,sha256=k6vuNLTOSUClMKI6My0-Xekkeu6hJrUyNib1TziuGag,3312
24
- xbarray/_src/implementations/numpy/__init__.py,sha256=s_tC8UT0ULs9tpZ5JFiEIOnv5sRAVBZFM5Wh90T44Wc,640
24
+ xbarray/_src/implementations/numpy/__init__.py,sha256=UcUDdf7xDp_oLw5O73G_n15qYzPd5XQsq4cnZoaX9y0,687
25
25
  xbarray/_src/implementations/numpy/_extra.py,sha256=p7WkiCWEl14A4W6lwo2TthKalsuAe7DuRhtQxJWf7ng,2003
26
26
  xbarray/_src/implementations/numpy/_typing.py,sha256=pgjLLAipwFsIk0QdgrAA4PEvjF_ugHbzfSTbLpA__6o,241
27
27
  xbarray/_src/implementations/numpy/random.py,sha256=C1z2-pMcDMRa7nKhKNTuY5LtTlu9nXvDpH1wY8mdIug,2630
28
- xbarray/_src/implementations/pytorch/__init__.py,sha256=CIXK76WnheuEkVjdU_efCgLxBx3ABhcTdbaImRzmkNM,643
28
+ xbarray/_src/implementations/pytorch/__init__.py,sha256=ZCGmZpbv4NaCWU_08G-ipEpI1xMr7QLXzEhwrhD7fI8,690
29
29
  xbarray/_src/implementations/pytorch/_extra.py,sha256=XBYZEYcia3JT7Uk2PT-DyiC-_9J_Rjtg3vQB04spXc8,2888
30
30
  xbarray/_src/implementations/pytorch/_typing.py,sha256=qSnNZD3IpgSoOTl3TBRBv2ifSAHOw0aR9uyzfV5KYVw,204
31
31
  xbarray/_src/implementations/pytorch/random.py,sha256=p4ZDsTc--z5XslVzel-iEVDtoKizrv39_1tfR4-469o,2657
@@ -34,8 +34,8 @@ xbarray/_src/serialization/serialization_map.py,sha256=05zfqip8qPCt-LgM_cx_zLc4y
34
34
  xbarray/base/__init__.py,sha256=ERmmOxz_9mUkIuccNbzUa5Y6gVLLVDdyc4cCxbCCUbY,20
35
35
  xbarray/base/base.py,sha256=V1yAXu2wUu6q50okX7JQ8onkGhHIQ0lkPkYOolwc45A,5928
36
36
  xbarray/cls_impl/cls_base.py,sha256=MUvJeMm4UVW4jXwfVP02GiCzqftrAND-JYvThge4PUw,312
37
- xbarray-0.0.1a3.dist-info/licenses/LICENSE,sha256=6P0HCOancSfch0dNycuDIe8_qwS0Id97Ih_8hjJ2PFI,1067
38
- xbarray-0.0.1a3.dist-info/METADATA,sha256=GQAkLlOrxDmTlTR7Tsex2UQ3mjvcVKqOxKlCy1bxBGE,436
39
- xbarray-0.0.1a3.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
40
- xbarray-0.0.1a3.dist-info/top_level.txt,sha256=VriXuFyU48Du4HQMzROSArhwqB6EZYY0n0mipgUqB9A,25
41
- xbarray-0.0.1a3.dist-info/RECORD,,
37
+ xbarray-0.0.1a4.dist-info/licenses/LICENSE,sha256=6P0HCOancSfch0dNycuDIe8_qwS0Id97Ih_8hjJ2PFI,1067
38
+ xbarray-0.0.1a4.dist-info/METADATA,sha256=Ij9lDaD2N4y8zUe5wU_QrXxtAJpDS1zmZmhU8RUli2I,436
39
+ xbarray-0.0.1a4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
40
+ xbarray-0.0.1a4.dist-info/top_level.txt,sha256=VriXuFyU48Du4HQMzROSArhwqB6EZYY0n0mipgUqB9A,25
41
+ xbarray-0.0.1a4.dist-info/RECORD,,