warp-lang 1.4.0__py3-none-macosx_10_13_universal2.whl → 1.4.1__py3-none-macosx_10_13_universal2.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 warp-lang might be problematic. Click here for more details.

Binary file
warp/bin/libwarp.dylib CHANGED
Binary file
warp/builtins.py CHANGED
@@ -2758,7 +2758,6 @@ add_builtin(
2758
2758
  "rand_init",
2759
2759
  input_types={"seed": int},
2760
2760
  value_type=uint32,
2761
- export=False,
2762
2761
  group="Random",
2763
2762
  doc="Initialize a new random number generator given a user-defined seed. Returns a 32-bit integer representing the RNG state.",
2764
2763
  )
@@ -2767,7 +2766,6 @@ add_builtin(
2767
2766
  "rand_init",
2768
2767
  input_types={"seed": int, "offset": int},
2769
2768
  value_type=uint32,
2770
- export=False,
2771
2769
  group="Random",
2772
2770
  doc="""Initialize a new random number generator given a user-defined seed and an offset.
2773
2771
 
@@ -2779,7 +2777,6 @@ add_builtin(
2779
2777
  "randi",
2780
2778
  input_types={"state": uint32},
2781
2779
  value_type=int,
2782
- export=False,
2783
2780
  group="Random",
2784
2781
  doc="Return a random integer in the range [0, 2^32).",
2785
2782
  )
@@ -2787,7 +2784,6 @@ add_builtin(
2787
2784
  "randi",
2788
2785
  input_types={"state": uint32, "low": int, "high": int},
2789
2786
  value_type=int,
2790
- export=False,
2791
2787
  group="Random",
2792
2788
  doc="Return a random integer between [low, high).",
2793
2789
  )
@@ -2795,7 +2791,6 @@ add_builtin(
2795
2791
  "randf",
2796
2792
  input_types={"state": uint32},
2797
2793
  value_type=float,
2798
- export=False,
2799
2794
  group="Random",
2800
2795
  doc="Return a random float between [0.0, 1.0).",
2801
2796
  )
@@ -2803,24 +2798,17 @@ add_builtin(
2803
2798
  "randf",
2804
2799
  input_types={"state": uint32, "low": float, "high": float},
2805
2800
  value_type=float,
2806
- export=False,
2807
2801
  group="Random",
2808
2802
  doc="Return a random float between [low, high).",
2809
2803
  )
2810
2804
  add_builtin(
2811
- "randn",
2812
- input_types={"state": uint32},
2813
- value_type=float,
2814
- export=False,
2815
- group="Random",
2816
- doc="Sample a normal distribution.",
2805
+ "randn", input_types={"state": uint32}, value_type=float, group="Random", doc="Sample a normal distribution."
2817
2806
  )
2818
2807
 
2819
2808
  add_builtin(
2820
2809
  "sample_cdf",
2821
2810
  input_types={"state": uint32, "cdf": array(dtype=float)},
2822
2811
  value_type=int,
2823
- export=False,
2824
2812
  group="Random",
2825
2813
  doc="Inverse-transform sample a cumulative distribution function.",
2826
2814
  )
@@ -2828,7 +2816,6 @@ add_builtin(
2828
2816
  "sample_triangle",
2829
2817
  input_types={"state": uint32},
2830
2818
  value_type=vec2,
2831
- export=False,
2832
2819
  group="Random",
2833
2820
  doc="Uniformly sample a triangle. Returns sample barycentric coordinates.",
2834
2821
  )
@@ -2836,7 +2823,6 @@ add_builtin(
2836
2823
  "sample_unit_ring",
2837
2824
  input_types={"state": uint32},
2838
2825
  value_type=vec2,
2839
- export=False,
2840
2826
  group="Random",
2841
2827
  doc="Uniformly sample a ring in the xy plane.",
2842
2828
  )
@@ -2844,7 +2830,6 @@ add_builtin(
2844
2830
  "sample_unit_disk",
2845
2831
  input_types={"state": uint32},
2846
2832
  value_type=vec2,
2847
- export=False,
2848
2833
  group="Random",
2849
2834
  doc="Uniformly sample a disk in the xy plane.",
2850
2835
  )
@@ -2852,7 +2837,6 @@ add_builtin(
2852
2837
  "sample_unit_sphere_surface",
2853
2838
  input_types={"state": uint32},
2854
2839
  value_type=vec3,
2855
- export=False,
2856
2840
  group="Random",
2857
2841
  doc="Uniformly sample a unit sphere surface.",
2858
2842
  )
@@ -2860,7 +2844,6 @@ add_builtin(
2860
2844
  "sample_unit_sphere",
2861
2845
  input_types={"state": uint32},
2862
2846
  value_type=vec3,
2863
- export=False,
2864
2847
  group="Random",
2865
2848
  doc="Uniformly sample a unit sphere.",
2866
2849
  )
@@ -2868,7 +2851,6 @@ add_builtin(
2868
2851
  "sample_unit_hemisphere_surface",
2869
2852
  input_types={"state": uint32},
2870
2853
  value_type=vec3,
2871
- export=False,
2872
2854
  group="Random",
2873
2855
  doc="Uniformly sample a unit hemisphere surface.",
2874
2856
  )
@@ -2876,7 +2858,6 @@ add_builtin(
2876
2858
  "sample_unit_hemisphere",
2877
2859
  input_types={"state": uint32},
2878
2860
  value_type=vec3,
2879
- export=False,
2880
2861
  group="Random",
2881
2862
  doc="Uniformly sample a unit hemisphere.",
2882
2863
  )
@@ -2884,7 +2865,6 @@ add_builtin(
2884
2865
  "sample_unit_square",
2885
2866
  input_types={"state": uint32},
2886
2867
  value_type=vec2,
2887
- export=False,
2888
2868
  group="Random",
2889
2869
  doc="Uniformly sample a unit square.",
2890
2870
  )
@@ -2892,7 +2872,6 @@ add_builtin(
2892
2872
  "sample_unit_cube",
2893
2873
  input_types={"state": uint32},
2894
2874
  value_type=vec3,
2895
- export=False,
2896
2875
  group="Random",
2897
2876
  doc="Uniformly sample a unit cube.",
2898
2877
  )
@@ -2901,7 +2880,6 @@ add_builtin(
2901
2880
  "poisson",
2902
2881
  input_types={"state": uint32, "lam": float},
2903
2882
  value_type=uint32,
2904
- export=False,
2905
2883
  group="Random",
2906
2884
  doc="""Generate a random sample from a Poisson distribution.
2907
2885
 
warp/codegen.py CHANGED
@@ -777,6 +777,9 @@ def func_match_args(func, arg_types, kwarg_types):
777
777
 
778
778
 
779
779
  def get_arg_type(arg: Union[Var, Any]):
780
+ if isinstance(arg, str):
781
+ return str
782
+
780
783
  if isinstance(arg, Sequence):
781
784
  return tuple(get_arg_type(x) for x in arg)
782
785
 
@@ -936,7 +939,7 @@ class Adjoint:
936
939
 
937
940
  adj.return_var = None # return type for function or kernel
938
941
  adj.loop_symbols = [] # symbols at the start of each loop
939
- adj.loop_const_iter_symbols = set() # iteration variables (constant) for static loops
942
+ adj.loop_const_iter_symbols = [] # iteration variables (constant) for static loops
940
943
 
941
944
  # blocks
942
945
  adj.blocks = [Block()]
@@ -1846,7 +1849,7 @@ class Adjoint:
1846
1849
  # detect symbols with conflicting definitions (assigned inside the for loop)
1847
1850
  for items in symbols.items():
1848
1851
  sym = items[0]
1849
- if adj.loop_const_iter_symbols is not None and sym in adj.loop_const_iter_symbols:
1852
+ if adj.is_constant_iter_symbol(sym):
1850
1853
  # ignore constant overwriting in for-loops if it is a loop iterator
1851
1854
  # (it is no problem to unroll static loops multiple times in sequence)
1852
1855
  continue
@@ -1998,11 +2001,21 @@ class Adjoint:
1998
2001
  return range_call
1999
2002
 
2000
2003
  def begin_record_constant_iter_symbols(adj):
2001
- if adj.loop_const_iter_symbols is None:
2002
- adj.loop_const_iter_symbols = set()
2004
+ if len(adj.loop_const_iter_symbols) > 0:
2005
+ adj.loop_const_iter_symbols.append(adj.loop_const_iter_symbols[-1])
2006
+ else:
2007
+ adj.loop_const_iter_symbols.append(set())
2003
2008
 
2004
2009
  def end_record_constant_iter_symbols(adj):
2005
- adj.loop_const_iter_symbols = None
2010
+ if len(adj.loop_const_iter_symbols) > 0:
2011
+ adj.loop_const_iter_symbols.pop()
2012
+
2013
+ def record_constant_iter_symbol(adj, sym):
2014
+ if len(adj.loop_const_iter_symbols) > 0:
2015
+ adj.loop_const_iter_symbols[-1].add(sym)
2016
+
2017
+ def is_constant_iter_symbol(adj, sym):
2018
+ return len(adj.loop_const_iter_symbols) > 0 and sym in adj.loop_const_iter_symbols[-1]
2006
2019
 
2007
2020
  def emit_For(adj, node):
2008
2021
  # try and unroll simple range() statements that use constant args
@@ -2010,9 +2023,8 @@ class Adjoint:
2010
2023
 
2011
2024
  if isinstance(unroll_range, range):
2012
2025
  const_iter_sym = node.target.id
2013
- if adj.loop_const_iter_symbols is not None:
2014
- # prevent constant conflicts in `materialize_redefinitions()`
2015
- adj.loop_const_iter_symbols.add(const_iter_sym)
2026
+ # prevent constant conflicts in `materialize_redefinitions()`
2027
+ adj.record_constant_iter_symbol(const_iter_sym)
2016
2028
 
2017
2029
  # unroll static for-loop
2018
2030
  for i in unroll_range:
warp/config.py CHANGED
@@ -7,7 +7,7 @@
7
7
 
8
8
  from typing import Optional
9
9
 
10
- version: str = "1.4.0"
10
+ version: str = "1.4.1"
11
11
  """Warp version string"""
12
12
 
13
13
  verify_fp: bool = False
warp/context.py CHANGED
@@ -6,7 +6,6 @@
6
6
  # license agreement from NVIDIA CORPORATION is strictly prohibited.
7
7
 
8
8
  import ast
9
- import builtins
10
9
  import ctypes
11
10
  import functools
12
11
  import hashlib
@@ -22,7 +21,6 @@ import typing
22
21
  import weakref
23
22
  from copy import copy as shallowcopy
24
23
  from pathlib import Path
25
- from struct import pack as struct_pack
26
24
  from typing import Any, Callable, Dict, List, Mapping, Optional, Sequence, Tuple, Union
27
25
 
28
26
  import numpy as np
@@ -1487,30 +1485,16 @@ class ModuleHasher:
1487
1485
  # hash referenced constants
1488
1486
  for name, value in constants.items():
1489
1487
  ch.update(bytes(name, "utf-8"))
1490
- # hash the referenced object
1491
- if isinstance(value, builtins.bool):
1492
- # This needs to come before the check for `int` since all boolean
1493
- # values are also instances of `int`.
1494
- ch.update(struct_pack("?", value))
1495
- elif isinstance(value, int):
1496
- ch.update(struct_pack("<q", value))
1497
- elif isinstance(value, float):
1498
- ch.update(struct_pack("<d", value))
1499
- elif isinstance(value, warp.types.float16):
1500
- # float16 is a special case
1501
- p = ctypes.pointer(ctypes.c_float(value.value))
1502
- ch.update(p.contents)
1503
- elif isinstance(value, tuple(warp.types.scalar_types)):
1504
- p = ctypes.pointer(value._type_(value.value))
1505
- ch.update(p.contents)
1506
- elif isinstance(value, ctypes.Array):
1507
- ch.update(bytes(value))
1508
- else:
1509
- raise RuntimeError(f"Invalid constant type: {type(value)}")
1488
+ ch.update(self.get_constant_bytes(value))
1510
1489
 
1511
1490
  # hash wp.static() expressions that were evaluated at declaration time
1512
1491
  for k, v in adj.static_expressions.items():
1513
- ch.update(bytes(f"{k} = {v}", "utf-8"))
1492
+ ch.update(bytes(k, "utf-8"))
1493
+ if isinstance(v, Function):
1494
+ if v not in self.functions_in_progress:
1495
+ ch.update(self.hash_function(v))
1496
+ else:
1497
+ ch.update(self.get_constant_bytes(v))
1514
1498
 
1515
1499
  # hash referenced types
1516
1500
  for t in types.keys():
@@ -1523,6 +1507,24 @@ class ModuleHasher:
1523
1507
 
1524
1508
  return ch.digest()
1525
1509
 
1510
+ def get_constant_bytes(self, value):
1511
+ if isinstance(value, int):
1512
+ # this also handles builtins.bool
1513
+ return bytes(ctypes.c_int(value))
1514
+ elif isinstance(value, float):
1515
+ return bytes(ctypes.c_float(value))
1516
+ elif isinstance(value, warp.types.float16):
1517
+ # float16 is a special case
1518
+ return bytes(ctypes.c_float(value.value))
1519
+ elif isinstance(value, tuple(warp.types.scalar_and_bool_types)):
1520
+ return bytes(value._type_(value.value))
1521
+ elif hasattr(value, "_wp_scalar_type_"):
1522
+ return bytes(value)
1523
+ elif isinstance(value, warp.codegen.StructInstance):
1524
+ return bytes(value._ctype)
1525
+ else:
1526
+ raise TypeError(f"Invalid constant type: {type(value)}")
1527
+
1526
1528
  def get_module_hash(self):
1527
1529
  return self.module_hash
1528
1530
 
@@ -143,7 +143,7 @@ def gen_hexmesh(res, bounds_lo: Optional[wp.vec3] = None, bounds_hi: Optional[wp
143
143
 
144
144
  x = np.linspace(bounds_lo[0], bounds_hi[0], Nx + 1)
145
145
  y = np.linspace(bounds_lo[1], bounds_hi[1], Ny + 1)
146
- z = np.linspace(bounds_lo[1], bounds_hi[1], Nz + 1)
146
+ z = np.linspace(bounds_lo[2], bounds_hi[2], Nz + 1)
147
147
 
148
148
  positions = np.transpose(np.meshgrid(x, y, z, indexing="ij"), axes=(1, 2, 3, 0)).reshape(-1, 3)
149
149
 
@@ -252,6 +252,7 @@ def bsr_cg(
252
252
  check_every=check_every,
253
253
  M=M,
254
254
  callback=callback,
255
+ use_cuda_graph=not wp.config.verify_cuda,
255
256
  )
256
257
 
257
258
  if not quiet:
warp/fem/utils.py CHANGED
@@ -193,9 +193,14 @@ def _givens_rotation(a: Any, b: Any):
193
193
  # Givens rotation [[c -s], [s c]] such that sa+cb =0
194
194
  zero = type(a)(0.0)
195
195
  one = type(a)(1.0)
196
- abn_sq = a * a + b * b
197
- abn = wp.select(abn_sq == zero, one / wp.sqrt(abn_sq), zero)
198
- return a * abn, -b * abn
196
+
197
+ b2 = b * b
198
+ if b2 == zero:
199
+ # id rotation
200
+ return one, zero
201
+
202
+ scale = one / wp.sqrt(a * a + b2)
203
+ return a * scale, -b * scale
199
204
 
200
205
 
201
206
  @wp.func
@@ -229,7 +234,7 @@ def tridiagonal_symmetric_eigenvalues_qr(D: Any, L: Any, Q: Any, tol: Any):
229
234
  x = D.dtype(0.0) # coeff atop buldge
230
235
 
231
236
  for _ in range(32 * m): # failsafe, usually converges faster than that
232
- # Iterate over all idependant (deflated) blocks
237
+ # Iterate over all independent (deflated) blocks
233
238
  end = int(-1)
234
239
 
235
240
  for k in range(m - 1):
warp/native/bvh.cu CHANGED
@@ -65,7 +65,7 @@ __global__ void bvh_refit_kernel(int n, const int* __restrict__ parents, int* __
65
65
  int finished = atomicAdd(&child_count[parent], 1);
66
66
 
67
67
  // if we have are the last thread (such that the parent node is now complete)
68
- // then update its bounds and move onto the the next parent in the hierarchy
68
+ // then update its bounds and move onto the next parent in the hierarchy
69
69
  if (finished == 1)
70
70
  {
71
71
  const int left_child = node_lowers[parent].i;
@@ -273,7 +273,7 @@ __global__ void build_hierarchy(int n, int* root, const int* __restrict__ deltas
273
273
  }
274
274
 
275
275
  // if we have are the last thread (such that the parent node is now complete)
276
- // then update its bounds and move onto the the next parent in the hierarchy
276
+ // then update its bounds and move onto the next parent in the hierarchy
277
277
  if (childCount == 1)
278
278
  {
279
279
  const int left_child = lowers[parent].i;
warp/native/exports.h CHANGED
@@ -1013,6 +1013,23 @@ WP_API void builtin_volume_index_to_world_uint64_vec3f(uint64 id, vec3f& uvw, ve
1013
1013
  WP_API void builtin_volume_world_to_index_uint64_vec3f(uint64 id, vec3f& xyz, vec3f* ret) { *ret = wp::volume_world_to_index(id, xyz); }
1014
1014
  WP_API void builtin_volume_index_to_world_dir_uint64_vec3f(uint64 id, vec3f& uvw, vec3f* ret) { *ret = wp::volume_index_to_world_dir(id, uvw); }
1015
1015
  WP_API void builtin_volume_world_to_index_dir_uint64_vec3f(uint64 id, vec3f& xyz, vec3f* ret) { *ret = wp::volume_world_to_index_dir(id, xyz); }
1016
+ WP_API void builtin_rand_init_int32(int32 seed, uint32* ret) { *ret = wp::rand_init(seed); }
1017
+ WP_API void builtin_rand_init_int32_int32(int32 seed, int32 offset, uint32* ret) { *ret = wp::rand_init(seed, offset); }
1018
+ WP_API void builtin_randi_uint32(uint32 state, int* ret) { *ret = wp::randi(state); }
1019
+ WP_API void builtin_randi_uint32_int32_int32(uint32 state, int32 low, int32 high, int* ret) { *ret = wp::randi(state, low, high); }
1020
+ WP_API void builtin_randf_uint32(uint32 state, float* ret) { *ret = wp::randf(state); }
1021
+ WP_API void builtin_randf_uint32_float32_float32(uint32 state, float32 low, float32 high, float* ret) { *ret = wp::randf(state, low, high); }
1022
+ WP_API void builtin_randn_uint32(uint32 state, float* ret) { *ret = wp::randn(state); }
1023
+ WP_API void builtin_sample_triangle_uint32(uint32 state, vec2f* ret) { *ret = wp::sample_triangle(state); }
1024
+ WP_API void builtin_sample_unit_ring_uint32(uint32 state, vec2f* ret) { *ret = wp::sample_unit_ring(state); }
1025
+ WP_API void builtin_sample_unit_disk_uint32(uint32 state, vec2f* ret) { *ret = wp::sample_unit_disk(state); }
1026
+ WP_API void builtin_sample_unit_sphere_surface_uint32(uint32 state, vec3f* ret) { *ret = wp::sample_unit_sphere_surface(state); }
1027
+ WP_API void builtin_sample_unit_sphere_uint32(uint32 state, vec3f* ret) { *ret = wp::sample_unit_sphere(state); }
1028
+ WP_API void builtin_sample_unit_hemisphere_surface_uint32(uint32 state, vec3f* ret) { *ret = wp::sample_unit_hemisphere_surface(state); }
1029
+ WP_API void builtin_sample_unit_hemisphere_uint32(uint32 state, vec3f* ret) { *ret = wp::sample_unit_hemisphere(state); }
1030
+ WP_API void builtin_sample_unit_square_uint32(uint32 state, vec2f* ret) { *ret = wp::sample_unit_square(state); }
1031
+ WP_API void builtin_sample_unit_cube_uint32(uint32 state, vec3f* ret) { *ret = wp::sample_unit_cube(state); }
1032
+ WP_API void builtin_poisson_uint32_float32(uint32 state, float32 lam, uint32* ret) { *ret = wp::poisson(state, lam); }
1016
1033
  WP_API void builtin_noise_uint32_float32(uint32 state, float32 x, float* ret) { *ret = wp::noise(state, x); }
1017
1034
  WP_API void builtin_noise_uint32_vec2f(uint32 state, vec2f& xy, float* ret) { *ret = wp::noise(state, xy); }
1018
1035
  WP_API void builtin_noise_uint32_vec3f(uint32 state, vec3f& xyz, float* ret) { *ret = wp::noise(state, xyz); }
warp/native/mesh.cu CHANGED
@@ -101,7 +101,7 @@ __global__ void bvh_refit_with_solid_angle_kernel(int n, const int* __restrict__
101
101
  int finished = atomicAdd(&child_count[parent], 1);
102
102
 
103
103
  // if we have are the last thread (such that the parent node is now complete)
104
- // then update its bounds and move onto the the next parent in the hierarchy
104
+ // then update its bounds and move onto the next parent in the hierarchy
105
105
  if (finished == 1)
106
106
  {
107
107
  //printf("Compute non-leaf at %d\n", index);
@@ -340,4 +340,4 @@ void mesh_set_velocities_device(uint64_t id, wp::array_t<wp::vec3> velocities)
340
340
  fprintf(stderr, "The mesh id provided to mesh_set_velocities_device is not valid!\n");
341
341
  return;
342
342
  }
343
- }
343
+ }
warp/native/range.h CHANGED
@@ -97,8 +97,17 @@ CUDA_CALLABLE inline range_t iter_reverse(const range_t& r)
97
97
  {
98
98
  // generates a reverse range, equivalent to reversed(range())
99
99
  range_t rev;
100
- rev.start = r.end-1;
101
- rev.end = r.start-1;
100
+
101
+ if (r.step > 0)
102
+ {
103
+ rev.start = r.start + int((r.end - r.start - 1) / r.step) * r.step;
104
+ }
105
+ else
106
+ {
107
+ rev.start = r.start + int((r.end - r.start + 1) / r.step) * r.step;
108
+ }
109
+
110
+ rev.end = r.start - r.step;
102
111
  rev.step = -r.step;
103
112
 
104
113
  rev.i = rev.start;
@@ -2808,12 +2808,8 @@ class XPBDIntegrator(Integrator):
2808
2808
 
2809
2809
  with wp.ScopedTimer("simulate", False):
2810
2810
  if model.particle_count:
2811
- if requires_grad:
2812
- particle_q = state_out.particle_q
2813
- particle_qd = state_out.particle_qd
2814
- else:
2815
- particle_q = state_out.particle_q
2816
- particle_qd = state_out.particle_qd
2811
+ particle_q = state_out.particle_q
2812
+ particle_qd = state_out.particle_qd
2817
2813
 
2818
2814
  self.particle_q_init = wp.clone(state_in.particle_q)
2819
2815
  if self.enable_restitution:
warp/sim/model.py CHANGED
@@ -641,7 +641,7 @@ class Model:
641
641
  joint_dof_count (int): Total number of velocity degrees of freedom of all joints in the system
642
642
  joint_coord_count (int): Total number of position degrees of freedom of all joints in the system
643
643
 
644
- particle_coloring (list of array): The coloring of all the particles, used for VBD's Gauss-Seidel interation.
644
+ particle_coloring (list of array): The coloring of all the particles, used for VBD's Gauss-Seidel iteration.
645
645
 
646
646
  device (wp.Device): Device on which the Model was allocated
647
647
 
@@ -1404,9 +1404,8 @@ class ModelBuilder:
1404
1404
  self.joint_X_p.extend(joint_X_p)
1405
1405
  self.joint_q.extend(joint_q)
1406
1406
 
1407
- self.add_articulation()
1408
-
1409
1407
  # offset the indices
1408
+ self.articulation_start.extend([a + self.joint_count for a in builder.articulation_start])
1410
1409
  self.joint_parent.extend([p + self.joint_count if p != -1 else -1 for p in builder.joint_parent])
1411
1410
  self.joint_child.extend([c + self.joint_count for c in builder.joint_child])
1412
1411
 
warp/sparse.py CHANGED
@@ -106,7 +106,7 @@ class BsrMatrix(Generic[_BlockType]):
106
106
  return
107
107
 
108
108
  BsrMatrix.__setattr__(
109
- self, "_nnz_buf", wp.zeros(dtype=int, shape=(1,), device="cpu", pinned=self.device.is_cuda)
109
+ self, "_nnz_buf", wp.empty(dtype=int, shape=(1,), device="cpu", pinned=self.device.is_cuda)
110
110
  )
111
111
  if self.device.is_cuda:
112
112
  BsrMatrix.__setattr__(self, "_nnz_event", wp.Event(self.device))
@@ -524,7 +524,7 @@ def _bsr_assign_split_blocks(
524
524
  if dest_block >= dest_offsets[dest_row_count]:
525
525
  return
526
526
 
527
- dest_row = wp.lower_bound(dest_offsets, dest_block + 1) - 1
527
+ dest_row = wp.lower_bound(dest_offsets, 0, dest_row_count + 1, dest_block + 1) - 1
528
528
  src_row = dest_row // row_factor
529
529
 
530
530
  dest_col_in_row = dest_block - dest_offsets[dest_row]
@@ -566,7 +566,7 @@ def _bsr_assign_merge_row_col(
566
566
  dest_rows[block] = -1 # invalid
567
567
  dest_cols[block] = -1
568
568
  else:
569
- row = wp.lower_bound(src_offsets, block + 1) - 1
569
+ row = wp.lower_bound(src_offsets, 0, src_row_count + 1, block + 1) - 1
570
570
  dest_rows[block] = row // row_factor
571
571
  dest_cols[block] = src_columns[block] // col_factor
572
572
 
@@ -589,7 +589,7 @@ def _bsr_assign_merge_blocks(
589
589
  if src_block >= src_offsets[src_row_count]:
590
590
  return
591
591
 
592
- src_row = wp.lower_bound(src_offsets, src_block + 1) - 1
592
+ src_row = wp.lower_bound(src_offsets, 0, src_row_count + 1, src_block + 1) - 1
593
593
  src_col = src_columns[src_block]
594
594
 
595
595
  dest_row = src_row // row_factor
@@ -828,7 +828,7 @@ def bsr_copy(
828
828
  block_type=block_type,
829
829
  device=A.device,
830
830
  )
831
- bsr_assign(dest=copy, src=A)
831
+ bsr_assign(dest=copy, src=A, structure_only=structure_only)
832
832
  return copy
833
833
 
834
834
 
@@ -1190,7 +1190,7 @@ def _bsr_get_block_row(dest_offset: int, row_count: int, bsr_offsets: wp.array(d
1190
1190
  if i >= bsr_offsets[row_count]:
1191
1191
  rows[dest_offset + i] = -1 # invalid
1192
1192
  else:
1193
- row = wp.lower_bound(bsr_offsets, i + 1) - 1
1193
+ row = wp.lower_bound(bsr_offsets, 0, row_count + 1, i + 1) - 1
1194
1194
  rows[dest_offset + i] = row
1195
1195
 
1196
1196
 
@@ -1461,13 +1461,14 @@ def _bsr_mm_compute_values(
1461
1461
  y_offsets: wp.array(dtype=int),
1462
1462
  y_columns: wp.array(dtype=int),
1463
1463
  y_values: wp.array(dtype=Any),
1464
+ mm_row_count: int,
1464
1465
  mm_offsets: wp.array(dtype=int),
1465
1466
  mm_cols: wp.array(dtype=int),
1466
1467
  mm_values: wp.array(dtype=Any),
1467
1468
  ):
1468
1469
  mm_block = wp.tid()
1469
1470
 
1470
- row = wp.lower_bound(mm_offsets, mm_block + 1) - 1
1471
+ row = wp.lower_bound(mm_offsets, 0, mm_row_count + 1, mm_block + 1) - 1
1471
1472
  col = mm_cols[mm_block]
1472
1473
 
1473
1474
  mm_val = mm_values.dtype(type(alpha)(0.0))
@@ -1759,6 +1760,7 @@ def bsr_mm(
1759
1760
  work_arrays._old_z_offsets if y == z else y.offsets,
1760
1761
  work_arrays._old_z_columns if y == z else y.columns,
1761
1762
  work_arrays._old_z_values if y == z else y.values,
1763
+ z.nrow,
1762
1764
  z.offsets,
1763
1765
  z.columns,
1764
1766
  mm_values,
@@ -503,6 +503,37 @@ def test_error_mutating_constant_in_dynamic_loop(test, device):
503
503
  ):
504
504
  wp.launch(dynamic_loop_kernel, dim=1, inputs=[3, inputs], device=device)
505
505
 
506
+ # the following nested loop must not raise an error
507
+ const_a = 7
508
+ const_b = 5
509
+
510
+ @wp.kernel
511
+ def mixed_dyn_static_loop_kernel(dyn_a: int, dyn_b: int, dyn_c: int, output: wp.array(dtype=float, ndim=2)):
512
+ tid = wp.tid()
513
+ for i in range(const_a + 1):
514
+ for j in range(dyn_a + 1):
515
+ for k in range(dyn_b + 1):
516
+ for l in range(const_b + 1):
517
+ for m in range(dyn_c + 1):
518
+ coeff = i + j + k + l + m
519
+ output[tid, coeff] = 1.0
520
+
521
+ dyn_a, dyn_b, dyn_c = 3, 4, 5
522
+ num_threads = 10
523
+ output = wp.empty([num_threads, const_a + const_b + dyn_a + dyn_b + dyn_c + 1], dtype=float, device=device)
524
+ wp.launch(
525
+ mixed_dyn_static_loop_kernel,
526
+ num_threads,
527
+ inputs=[
528
+ dyn_a,
529
+ dyn_b,
530
+ dyn_c,
531
+ ],
532
+ outputs=[output],
533
+ device=device,
534
+ )
535
+ assert_np_equal(output.numpy(), np.ones([num_threads, const_a + const_b + dyn_a + dyn_b + dyn_c + 1]))
536
+
506
537
 
507
538
  @wp.kernel
508
539
  def test_call_syntax():
warp/tests/test_fem.py CHANGED
@@ -28,6 +28,9 @@ from warp.fem.utils import (
28
28
  )
29
29
  from warp.tests.unittest_utils import *
30
30
 
31
+ vec6f = wp.vec(length=6, dtype=float)
32
+ mat66f = wp.mat(shape=(6, 6), dtype=float)
33
+
31
34
 
32
35
  @integrand
33
36
  def linear_form(s: Sample, u: Field):
@@ -1507,7 +1510,7 @@ def test_implicit_fields(test, device):
1507
1510
 
1508
1511
  @wp.kernel
1509
1512
  def test_qr_eigenvalues():
1510
- tol = 1.0e-6
1513
+ tol = 1.0e-8
1511
1514
 
1512
1515
  # zero
1513
1516
  Zero = wp.mat33(0.0)
@@ -1546,6 +1549,19 @@ def test_qr_eigenvalues():
1546
1549
  Err4 = wp.transpose(P4) * wp.diag(D4) * P4 - Rank4
1547
1550
  wp.expect_near(wp.ddot(Err4, Err4), 0.0, tol)
1548
1551
 
1552
+ # test robustness to low requested tolerance
1553
+ Rank6 = mat66f(
1554
+ vec6f(0.00171076, 0.0, 0.0, 0.0, 0.0, 0.0),
1555
+ vec6f(0.0, 0.00169935, 6.14367e-06, -3.52589e-05, 3.02397e-05, -1.53458e-11),
1556
+ vec6f(0.0, 6.14368e-06, 0.00172217, 2.03568e-05, 1.74589e-05, -2.92627e-05),
1557
+ vec6f(0.0, -3.52589e-05, 2.03568e-05, 0.00172178, 2.53422e-05, 3.02397e-05),
1558
+ vec6f(0.0, 3.02397e-05, 1.74589e-05, 2.53422e-05, 0.00171114, 3.52589e-05),
1559
+ vec6f(0.0, 6.42993e-12, -2.92627e-05, 3.02397e-05, 3.52589e-05, 0.00169935),
1560
+ )
1561
+ D6, P6 = symmetric_eigenvalues_qr(Rank6, 0.0)
1562
+ Err6 = wp.transpose(P6) * wp.diag(D6) * P6 - Rank6
1563
+ wp.expect_near(wp.ddot(Err6, Err6), 0.0, 1.0e-13)
1564
+
1549
1565
 
1550
1566
  @wp.kernel
1551
1567
  def test_qr_inverse():
warp/tests/test_model.py CHANGED
@@ -157,6 +157,19 @@ class TestModel(unittest.TestCase):
157
157
  assert builder.body_mass == [1.0, 4.0]
158
158
  assert builder.body_inv_mass == [1.0, 0.25]
159
159
 
160
+ # create another builder, test add_builder function
161
+ builder2 = ModelBuilder()
162
+ builder2.add_builder(builder)
163
+ assert builder2.articulation_count == builder.articulation_count
164
+ assert builder2.joint_count == builder.joint_count
165
+ assert builder2.body_count == builder.body_count
166
+ assert builder2.shape_count == builder.shape_count
167
+ assert builder2.articulation_start == builder.articulation_start
168
+ # add the same builder again
169
+ builder2.add_builder(builder)
170
+ assert builder2.articulation_count == 2 * builder.articulation_count
171
+ assert builder2.articulation_start == [0, 1, 2, 3]
172
+
160
173
 
161
174
  if __name__ == "__main__":
162
175
  wp.clear_kernel_cache()
warp/tests/test_static.py CHANGED
@@ -5,6 +5,8 @@
5
5
  # distribution of this software and related documentation without an express
6
6
  # license agreement from NVIDIA CORPORATION is strictly prohibited.
7
7
 
8
+ import importlib
9
+ import tempfile
8
10
  import unittest
9
11
  from typing import Dict, List
10
12
 
@@ -17,6 +19,23 @@ from warp.tests.unittest_utils import *
17
19
  global_variable = 3
18
20
 
19
21
 
22
+ def load_code_as_module(code, name):
23
+ file, file_path = tempfile.mkstemp(suffix=".py")
24
+
25
+ try:
26
+ with os.fdopen(file, "w") as f:
27
+ f.write(code)
28
+
29
+ spec = importlib.util.spec_from_file_location(name, file_path)
30
+ module = importlib.util.module_from_spec(spec)
31
+ spec.loader.exec_module(module)
32
+ finally:
33
+ os.remove(file_path)
34
+
35
+ # return Warp module
36
+ return wp.get_module(module.__name__)
37
+
38
+
20
39
  @wp.func
21
40
  def static_global_variable_func():
22
41
  static_var = warp.static(global_variable + 2)
@@ -234,7 +253,7 @@ def test_function_variable(test, device):
234
253
  results[0] = wp.static(func)(3, 2) # noqa: B023
235
254
 
236
255
  results = wp.zeros(1, dtype=int, device=device)
237
- # note that the kernel has to be recompiled everytime the value of func changes
256
+ # note that the kernel has to be recompiled every time the value of func changes
238
257
  wp.launch(function_variable_kernel, 1, [results], device=device)
239
258
  assert_np_equal(results.numpy(), np.array([func(3, 2)], dtype=int))
240
259
 
@@ -383,6 +402,140 @@ def test_static_if_else_elif(test, device):
383
402
  assert_np_equal(counts["else"], 0)
384
403
 
385
404
 
405
+ static_builtin_constant_template = """
406
+ import warp as wp
407
+
408
+ # Python builtin literal like 17, 42.0, or True
409
+ C = {value}
410
+
411
+ @wp.kernel
412
+ def k():
413
+ print(wp.static(C))
414
+ """
415
+
416
+ static_warp_constant_template = """
417
+ import warp as wp
418
+
419
+ # Warp scalar value like wp.uint8(17)
420
+ C = wp.{dtype}({value})
421
+
422
+ @wp.kernel
423
+ def k():
424
+ print(wp.static(C))
425
+ """
426
+
427
+ static_struct_constant_template = """
428
+ import warp as wp
429
+
430
+ @wp.struct
431
+ class SimpleStruct:
432
+ x: float
433
+
434
+ C = SimpleStruct()
435
+ C.x = {value}
436
+
437
+ @wp.kernel
438
+ def k():
439
+ print(wp.static(C))
440
+ """
441
+
442
+ static_func_template = """
443
+ import warp as wp
444
+
445
+ @wp.func
446
+ def f():
447
+ # modify the function to verify hashing
448
+ return {value}
449
+
450
+ @wp.kernel
451
+ def k():
452
+ print(wp.static(f)())
453
+ """
454
+
455
+
456
+ def test_static_constant_hash(test, _):
457
+ # Python literals
458
+ # (type, value1, value2)
459
+ literals = [
460
+ (int, 17, 42),
461
+ (float, 17.5, 42.5),
462
+ (bool, True, False),
463
+ ]
464
+
465
+ for builtin_type, value1, value2 in literals:
466
+ type_name = builtin_type.__name__
467
+ with test.subTest(msg=f"{type_name}"):
468
+ source1 = static_builtin_constant_template.format(value=value1)
469
+ source2 = static_builtin_constant_template.format(value=value2)
470
+ source3 = static_builtin_constant_template.format(value=value1)
471
+
472
+ module1 = load_code_as_module(source1, f"aux_static_constant_builtin_{type_name}_1")
473
+ module2 = load_code_as_module(source2, f"aux_static_constant_builtin_{type_name}_2")
474
+ module3 = load_code_as_module(source3, f"aux_static_constant_builtin_{type_name}_3")
475
+
476
+ hash1 = module1.hash_module()
477
+ hash2 = module2.hash_module()
478
+ hash3 = module3.hash_module()
479
+
480
+ test.assertNotEqual(hash1, hash2)
481
+ test.assertEqual(hash1, hash3)
482
+
483
+ # Warp types (scalars, vectors, matrices)
484
+ for warp_type in [*wp.types.scalar_types, *wp.types.vector_types]:
485
+ type_name = warp_type.__name__
486
+ with test.subTest(msg=f"wp.{type_name}"):
487
+ value1 = ", ".join([str(17)] * warp_type._length_)
488
+ value2 = ", ".join([str(42)] * warp_type._length_)
489
+ source1 = static_warp_constant_template.format(dtype=type_name, value=value1)
490
+ source2 = static_warp_constant_template.format(dtype=type_name, value=value2)
491
+ source3 = static_warp_constant_template.format(dtype=type_name, value=value1)
492
+
493
+ module1 = load_code_as_module(source1, f"aux_static_constant_wp_{type_name}_1")
494
+ module2 = load_code_as_module(source2, f"aux_static_constant_wp_{type_name}_2")
495
+ module3 = load_code_as_module(source3, f"aux_static_constant_wp_{type_name}_3")
496
+
497
+ hash1 = module1.hash_module()
498
+ hash2 = module2.hash_module()
499
+ hash3 = module3.hash_module()
500
+
501
+ test.assertNotEqual(hash1, hash2)
502
+ test.assertEqual(hash1, hash3)
503
+
504
+ # structs
505
+ with test.subTest(msg="struct"):
506
+ source1 = static_struct_constant_template.format(value=17)
507
+ source2 = static_struct_constant_template.format(value=42)
508
+ source3 = static_struct_constant_template.format(value=17)
509
+
510
+ module1 = load_code_as_module(source1, "aux_static_constant_struct_1")
511
+ module2 = load_code_as_module(source2, "aux_static_constant_struct_2")
512
+ module3 = load_code_as_module(source3, "aux_static_constant_struct_3")
513
+
514
+ hash1 = module1.hash_module()
515
+ hash2 = module2.hash_module()
516
+ hash3 = module3.hash_module()
517
+
518
+ test.assertNotEqual(hash1, hash2)
519
+ test.assertEqual(hash1, hash3)
520
+
521
+
522
+ def test_static_function_hash(test, _):
523
+ source1 = static_func_template.format(value=17)
524
+ source2 = static_func_template.format(value=42)
525
+ source3 = static_func_template.format(value=17)
526
+
527
+ module1 = load_code_as_module(source1, "aux_static_func1")
528
+ module2 = load_code_as_module(source2, "aux_static_func2")
529
+ module3 = load_code_as_module(source3, "aux_static_func3")
530
+
531
+ hash1 = module1.hash_module()
532
+ hash2 = module2.hash_module()
533
+ hash3 = module3.hash_module()
534
+
535
+ test.assertNotEqual(hash1, hash2)
536
+ test.assertEqual(hash1, hash3)
537
+
538
+
386
539
  devices = get_test_devices()
387
540
 
388
541
 
@@ -406,6 +559,9 @@ add_function_test(
406
559
  add_function_test(TestStatic, "test_static_for_loop", test_static_for_loop, devices=devices)
407
560
  add_function_test(TestStatic, "test_static_if_else_elif", test_static_if_else_elif, devices=devices)
408
561
 
562
+ add_function_test(TestStatic, "test_static_constant_hash", test_static_constant_hash, devices=None)
563
+ add_function_test(TestStatic, "test_static_function_hash", test_static_function_hash, devices=None)
564
+
409
565
 
410
566
  if __name__ == "__main__":
411
567
  wp.clear_kernel_cache()
warp/types.py CHANGED
@@ -2261,13 +2261,22 @@ class array(Array):
2261
2261
  self._requires_grad = False
2262
2262
  else:
2263
2263
  # make sure the given gradient array is compatible
2264
- if (
2265
- grad.dtype != self.dtype
2266
- or grad.shape != self.shape
2267
- or grad.strides != self.strides
2268
- or grad.device != self.device
2269
- ):
2270
- raise ValueError("The given gradient array is incompatible")
2264
+ if grad.dtype != self.dtype:
2265
+ raise ValueError(
2266
+ f"The given gradient array is incompatible: expected dtype {self.dtype}, got {grad.dtype}"
2267
+ )
2268
+ if grad.shape != self.shape:
2269
+ raise ValueError(
2270
+ f"The given gradient array is incompatible: expected shape {self.shape}, got {grad.shape}"
2271
+ )
2272
+ if grad.device != self.device:
2273
+ raise ValueError(
2274
+ f"The given gradient array is incompatible: expected device {self.device}, got {grad.device}"
2275
+ )
2276
+ if grad.strides != self.strides:
2277
+ raise ValueError(
2278
+ f"The given gradient array is incompatible: expected strides {self.strides}, got {grad.strides}"
2279
+ )
2271
2280
  self._grad = grad
2272
2281
  self._requires_grad = True
2273
2282
 
@@ -3465,7 +3474,7 @@ class Volume:
3465
3474
  )
3466
3475
 
3467
3476
  def feature_array(self, feature_index: int, dtype=None) -> array:
3468
- """Returns one the the grid's feature data arrays as a Warp array
3477
+ """Returns one the grid's feature data arrays as a Warp array
3469
3478
 
3470
3479
  Args:
3471
3480
  feature_index: Index of the supplemental data array in the grid
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: warp-lang
3
- Version: 1.4.0
3
+ Version: 1.4.1
4
4
  Summary: A Python framework for high-performance simulation and graphics programming
5
5
  Author-email: NVIDIA Corporation <mmacklin@nvidia.com>
6
6
  License: NVIDIA Software License
@@ -77,9 +77,9 @@ the `pip install` command, e.g.
77
77
 
78
78
  | Platform | Install Command |
79
79
  | --------------- | ----------------------------------------------------------------------------------------------------------------------------- |
80
- | Linux aarch64 | `pip install https://github.com/NVIDIA/warp/releases/download/v1.4.0/warp_lang-1.4.0+cu11-py3-none-manylinux2014_aarch64.whl` |
81
- | Linux x86-64 | `pip install https://github.com/NVIDIA/warp/releases/download/v1.4.0/warp_lang-1.4.0+cu11-py3-none-manylinux2014_x86_64.whl` |
82
- | Windows x86-64 | `pip install https://github.com/NVIDIA/warp/releases/download/v1.4.0/warp_lang-1.4.0+cu11-py3-none-win_amd64.whl` |
80
+ | Linux aarch64 | `pip install https://github.com/NVIDIA/warp/releases/download/v1.4.1/warp_lang-1.4.1+cu11-py3-none-manylinux2014_aarch64.whl` |
81
+ | Linux x86-64 | `pip install https://github.com/NVIDIA/warp/releases/download/v1.4.1/warp_lang-1.4.1+cu11-py3-none-manylinux2014_x86_64.whl` |
82
+ | Windows x86-64 | `pip install https://github.com/NVIDIA/warp/releases/download/v1.4.1/warp_lang-1.4.1+cu11-py3-none-win_amd64.whl` |
83
83
 
84
84
  The `--force-reinstall` option may need to be used to overwrite a previous installation.
85
85
 
@@ -3,24 +3,24 @@ warp/__init__.pyi,sha256=Vxal9LM-q5ztScfRhrM4INpm5LJV6fN6B-H2NI5pkyU,21
3
3
  warp/autograd.py,sha256=5-ClvT3AwDQfUcpgDlVN7D4tFFzqqjBJrEMTM_Ag4gk,35700
4
4
  warp/build.py,sha256=N2-SDksxkffUkzV97dtLW2Wjqd5ERfgwpqzVoe8GNRw,3904
5
5
  warp/build_dll.py,sha256=jJYepplaVXRdLL_ug4QlR6w7TSjyHB8zr1EyfZROOgA,15801
6
- warp/builtins.py,sha256=gJndZJZ03HBkEdA_Ri9wfYs5iuzQpR5ULRw39F8TYhM,146096
7
- warp/codegen.py,sha256=kAhfMF5RfqC1vYhN1EZDYddfiSsiH9GUOR9yrnIEzBA,133509
8
- warp/config.py,sha256=iNbaVCVfM_C4U6iOxUaNSrEoJg4MwzbkwGyY1hvArQk,2808
6
+ warp/builtins.py,sha256=g1lDmyGZnFU_1jBPMzzYRdJPyPG9kbhbfuDicNBd21w,145755
7
+ warp/codegen.py,sha256=5MLNdPhHGrdxZCDsV1IgmssZ2LEBBd_lB66P4qvWECU,133887
8
+ warp/config.py,sha256=nmywCBQORl5fHziFpCqT17fYbqxDCUtM9hTDEPyQkJ4,2808
9
9
  warp/constants.py,sha256=ckfEqwbg109RJDW98SILe_yfOBEFolOATVjt0mU2py4,1321
10
- warp/context.py,sha256=9zZG0K0zez7K0ThLw3KU5bD_raBQfAtLjJ-l7s56JzI,238090
10
+ warp/context.py,sha256=w0G-nmuzzg9XEina3ovCPijAr-A9PjG9XYXYuZCjT_Q,238071
11
11
  warp/dlpack.py,sha256=jyQdL-2c6zM-r5P0DZBCTSkBoRpbmWChvcn3GvGBKIE,16853
12
12
  warp/fabric.py,sha256=qWOomvuhM2y3EzScsgaj_Dxvdt0wJPfFu4jUUG1JALg,11439
13
13
  warp/jax.py,sha256=QKJXfpz1jjaRD-Yp4C4wC4jUv8jHj0en3MW0VXKq0ZA,5280
14
14
  warp/jax_experimental.py,sha256=1WFrXcZk3U9SzqM5NJmpuCd1h29tWfvwZRA7b9JIecs,13930
15
15
  warp/paddle.py,sha256=afh5f7n37IRaDiRimFlI4xqW6p7xTPx61wnTkotOUS8,14862
16
- warp/sparse.py,sha256=APAp2M2FNpmOaQkI-ddxjluEcwJ-Ua2plNwq8IdP_Gw,64640
16
+ warp/sparse.py,sha256=tKF7IdiNZB9WpU9t5rFp5t2W4dVa8kacK6dFNA9RE00,64820
17
17
  warp/stubs.py,sha256=vqSKm0q1ptkqhtq1iA1Yepn7Bzrde-tJsnE0P_YZ9wI,67864
18
18
  warp/tape.py,sha256=X979fk8oSsJiv-VQyz2AMhAm2udDk2bngx-_zKHIJyo,49015
19
19
  warp/torch.py,sha256=jv3SYQHVKsiCzenlWUVmVs5mLYfsWcdTW446IqvEwVA,14505
20
- warp/types.py,sha256=5zdL67hnDpIT3gzFkFyUMawVjrtgXIj1acnZpk90b_g,180802
20
+ warp/types.py,sha256=HIBjH5N1-n20oOkLUIHJX6rzGbeEFis-REKu2h1VxFY,181341
21
21
  warp/utils.py,sha256=T07usjsWbggZTH1jvWd-W4ucWcWOEsLSdv8443LseJ8,35993
22
- warp/bin/libwarp-clang.dylib,sha256=VVPOAD2ah2XtUekWrQ4wl-pHLbRFjTsDfuxpcvPZYRE,106702184
23
- warp/bin/libwarp.dylib,sha256=QIT_Izt3gI4JTnQ_g4NnXl51w9aUW7HRP4aMHEJt_Ik,902824
22
+ warp/bin/libwarp-clang.dylib,sha256=Gz_iQRlDMaVXUZnyFc-4TxoMnz1JrQ53D4XBEs5LuFc,106702184
23
+ warp/bin/libwarp.dylib,sha256=8vEooa9N2-Z7d1wKaBx2HU7TnLmTClyKJNlNBj-d4Ok,953736
24
24
  warp/examples/__init__.py,sha256=ul3vRFtQ17_zIZIWJaCnCY28KZTGOUHQA4wA_IW_qaw,606
25
25
  warp/examples/browse.py,sha256=6v7F0vpZz5ZtYGkg8hIpxhbIZ2ECv46cIKAmKVtV1S4,848
26
26
  warp/examples/assets/bear.usd,sha256=1SK7s-zpF3Ypzcc8Wt861o174Pe-xMuJpvosACXVNUk,226238
@@ -75,7 +75,7 @@ warp/examples/fem/example_nonconforming_contact.py,sha256=APIbR11KU52zVe6_zgObuk
75
75
  warp/examples/fem/example_stokes.py,sha256=7wM-bf1mjfj8r0urpBjH1Vm6bQfc2X8yUr9PnPph_n0,7154
76
76
  warp/examples/fem/example_stokes_transfer.py,sha256=UhgR5f2yXVavVYhmuMoOzKApg--MXYCD0r5eeHJ3vDs,9366
77
77
  warp/examples/fem/example_streamlines.py,sha256=a-RtZrpqngulgfc8MlJ010qZC7kW5iGKsCYT4HGBRlc,12266
78
- warp/examples/fem/utils.py,sha256=aZX5_6xWuHhSZKC0S3Qof3-2paUDWA9PieuwCpnaFBo,32112
78
+ warp/examples/fem/utils.py,sha256=jSS_3iQMTrtNP0b-a1wVmw4OBO9P_5X-wAmZNyjtbYo,32162
79
79
  warp/examples/optim/example_bounce.py,sha256=V4t9pKXGXv91C-S9-e5YV6ENSgOpK2cyHmPl1q3-zKQ,8470
80
80
  warp/examples/optim/example_cloth_throw.py,sha256=mj170UWAhWu4EGQwVgqp08ijoHvwZXlCC4WAa3sl0QE,7213
81
81
  warp/examples/optim/example_diffray.py,sha256=GiSmgqlN_j33uFuJ8KChJJwYpABkhUvII-YeQrOmZqo,18545
@@ -107,7 +107,7 @@ warp/fem/integrate.py,sha256=mLKHQMgTu8qbN4TOp7DWlV0kNTZBxhi5R2-XfaWMhCo,62264
107
107
  warp/fem/operator.py,sha256=W57PueA32kXd8AFl89ra53LLwO19jsRpFDkclsnwPMI,6383
108
108
  warp/fem/polynomial.py,sha256=feVKe3Yv8M53vCC57dhW7aq698DgnAilNOvvi_BnBY0,6565
109
109
  warp/fem/types.py,sha256=TA6rsT61qIC0a62FEiNrNBPbjz1rhMqF8SqZgFKKcGk,2331
110
- warp/fem/utils.py,sha256=ESZ6WWERWZxVB1NTPIhtYW63cAbpb2YtJXaR_--y1_w,22865
110
+ warp/fem/utils.py,sha256=4Io5rTsEt5Bokf3hAupLqXBO0wcqRWi_U6s-nlFQPA8,22899
111
111
  warp/fem/field/__init__.py,sha256=WGklY2f5nuXLA9TstvWvHJq9AZRxb4kvPihxb1OZHcM,4020
112
112
  warp/fem/field/field.py,sha256=zGA-nrkirNIBYH7umYT1gvI5sK6qudzhZkR6nIAhofc,21124
113
113
  warp/fem/field/nodal_field.py,sha256=g-6zUAt3GKRAPBwt1ZcK38_7KblZwzKweSRJQJ-xQQY,12746
@@ -155,7 +155,7 @@ warp/fem/space/shape/triangle_shape_function.py,sha256=XIH1-NFHaMmuFXlzNc07bAMlV
155
155
  warp/native/array.h,sha256=vXJLJjo5nA-QW10y7T6TjVnBHM8utXv4OZEDL3cMj98,38984
156
156
  warp/native/builtin.h,sha256=D-OzDu5QoCq3p0I_bPy9WVaYupO4VY5IRcB2_3zUAaM,50684
157
157
  warp/native/bvh.cpp,sha256=PAETbl9RNUqVmJA25wNrg9_3wnGLkykaRubj2ExdKGY,10474
158
- warp/native/bvh.cu,sha256=e7ATGMSneNYoBMXcSwtoPOfEisZsEBo_wVAz6XRjWR8,19379
158
+ warp/native/bvh.cu,sha256=G6LuuUVwULtOkhAL2mem8LENFP-dACv35SQu7bScaYY,19371
159
159
  warp/native/bvh.h,sha256=GG0aPcT5p7xAJv7dK3MlE-C14ss7iepksAeIwintons,10188
160
160
  warp/native/crt.cpp,sha256=_2AwFMh_1Q_XIP9lsbc6q74_3HQOl65YpCejKbZ_0aE,1167
161
161
  warp/native/crt.h,sha256=HeMvgbN_8BlITJ2_JkmyGlGra3btP36_rF7K-bnwPuo,10788
@@ -166,7 +166,7 @@ warp/native/cutlass_gemm.cpp,sha256=AlBnMgeO-veCYV-Y5NHEmOLnWKvzTQIPxSzg75Z7Tpk,
166
166
  warp/native/cutlass_gemm.cu,sha256=0ReIwBKKp6S2TaPPAFKIg2pBHItF707NoPjXhwvdG54,21615
167
167
  warp/native/error.cpp,sha256=vZPoPOWNZxYEhKckC8wTfnrMuZgGcog3uo2j1DprwSA,1907
168
168
  warp/native/error.h,sha256=LL74-rb8cackiu7NvHdu8zezVOVsG-ERr8gyqvqIhwQ,934
169
- warp/native/exports.h,sha256=0hxbQYi0XG61m6aT8uWQCMBG1p7n8imRUdiChUREJug,180658
169
+ warp/native/exports.h,sha256=cyX7gP6hV8lPzUo5Jh932kmhGRkz7Mo4EjxAZAzYv44,182600
170
170
  warp/native/fabric.h,sha256=XcTNQx0sbvfSYdVSDPhos9uhH1Z96zylzMFQLuOHSj4,5750
171
171
  warp/native/hashgrid.cpp,sha256=xP3KzWKaE_6_5EQ72Abj-1jJ7ocYitQBXXX0zNgL37A,8429
172
172
  warp/native/hashgrid.cu,sha256=LSHjbh5ehUBoqR1sFAvwGB0KBB3bBGIrF9c9cZnz89c,2259
@@ -181,12 +181,12 @@ warp/native/marching.h,sha256=NukjDs_VrVC-BXDtIeFhOQFwztYbC9U80UCzr-KGhAg,14
181
181
  warp/native/mat.h,sha256=d4YuecbJIjCI8bh6O8ck4-GBYgm_srNL6rW5oQpEPrg,51348
182
182
  warp/native/matnn.h,sha256=7PQLOe4cUuL5X7Fi6kVKAqORvz6JMXJHLsDviBMxOZQ,9617
183
183
  warp/native/mesh.cpp,sha256=dv1YzFlFxE3HXFWhLgqcHxwAn7JCipJ2jKvai1h90XU,6958
184
- warp/native/mesh.cu,sha256=1BysYvOoqKbxyuqq_rj-RnCD9jWfaztBYykLo4mM94s,11984
184
+ warp/native/mesh.cu,sha256=hKXK3hj5SqByV5TcTB2ugNpwAqc6CaQiylfagtBlFPk,11981
185
185
  warp/native/mesh.h,sha256=zMcdlCop5VrEK7tIpCfYXnV5NqoTRUwz3PBY1x8Ex_Q,59646
186
186
  warp/native/noise.h,sha256=fOH_JY0S9h-HSyYim6EdXWGncBIa8Tb0Ngwbkb4HUgw,29762
187
187
  warp/native/quat.h,sha256=yuC6qUbtUw96scTAbbk_O55eA1QNFLEq0luyCTFzPwc,42584
188
188
  warp/native/rand.h,sha256=oAsX4qPmrgMoqG1ObtpU63leDPX6tIHTiR448aLGyKE,11781
189
- warp/native/range.h,sha256=D7BLpAA_RXXrWXVcWm6oxZfuaSBCO_U_lFSclI1FQbU,2315
189
+ warp/native/range.h,sha256=qLZFvPygGtClsTh1mtErho6yEXIpyWKN87HliglY2Ac,2504
190
190
  warp/native/reduce.cpp,sha256=TrZLQePN8GpoHsWQRbvgnknbD2Bjgl0PuD1JsnmAVMk,4460
191
191
  warp/native/reduce.cu,sha256=FkNLEQF8DlP5PbDe0AMavxwFs88634gYKce0OO_xZfc,10667
192
192
  warp/native/runlength_encode.cpp,sha256=QSPu8CV-2jJh7Nh-_5Om-WxirBjpfrALvQdlOgpB9F4,1325
@@ -238,8 +238,8 @@ warp/sim/integrator.py,sha256=5UZYDdL6IyQaL6eGc1UQLrLcOrCD0dHmZWgG0K2kCGA,6652
238
238
  warp/sim/integrator_euler.py,sha256=OEg0T6aajoX1dEDq0g9OdP1nSOevVCKzv32wNkwQUOI,59787
239
239
  warp/sim/integrator_featherstone.py,sha256=f2CS2zoCUaOZSwf2-3w0YeUVuxf3qHCk2nEA-4tQpjg,64873
240
240
  warp/sim/integrator_vbd.py,sha256=XZyAmlTeU0GSuv4V_X36ELmtLwYd6zEckvNE_46OuQc,38718
241
- warp/sim/integrator_xpbd.py,sha256=oJmTNO3UK6NlC7GLmzsoTb0dV44RM4DvqwVqIlUQkGs,115198
242
- warp/sim/model.py,sha256=3ClBoHbR2aev_Fffv-YZyxRtjuuuccB9sJiK7X99z30,193231
241
+ warp/sim/integrator_xpbd.py,sha256=j11n_X2xBu5CkP66qbybNg-wVH3hw8nhkkJUFvOsqsk,115024
242
+ warp/sim/model.py,sha256=oSwxDY8_nZccrgsoNsZ782CG9YqlOknsaBSFh9Hrsn8,193296
243
243
  warp/sim/particles.py,sha256=wVK-LEKZy9TGYyRnmna_p2Q24zZaorZf8EdUizM4VCo,3165
244
244
  warp/sim/render.py,sha256=XDNflQIqu3XXzVhwR7wC72-8Z3WgEVuEYoo_sDFaOLg,17874
245
245
  warp/sim/utils.py,sha256=WrXAMBi1ufZJpISo4rQfOMGx7u4F3moHDeQW-v8ukyU,12201
@@ -269,7 +269,7 @@ warp/tests/test_bool.py,sha256=f-9kM--pYSg176KD9gRMOdnADfu8HP1ZnZEjvOYPjug,6472
269
269
  warp/tests/test_builtins_resolution.py,sha256=ixoOhKgOgbuH-xbqNLx1DB1Nur3PdAtR0qW-TutaHrI,63989
270
270
  warp/tests/test_bvh.py,sha256=mr7sRxB1AaQWetCzDIOsW38aWWMwIhfbZBMkjZcKr0M,6123
271
271
  warp/tests/test_closest_point_edge_edge.py,sha256=mtiiZOHqgGOHoD6KNK4jVP-9OoCUWwnuOBVB9M3uGlc,9560
272
- warp/tests/test_codegen.py,sha256=izRRZdVludGcFE3UKq_pDw8_f4LgK0k0GwBIVvWnIdI,17550
272
+ warp/tests/test_codegen.py,sha256=5onVI7Inna0B_OTZKDdTpgEaUc9qE3MlBEek6MzHhT4,18606
273
273
  warp/tests/test_codegen_instancing.py,sha256=PRExiuwPpXOwLWnB62eSMgOldZeqPFEKEC537O2N6cI,40664
274
274
  warp/tests/test_collision.py,sha256=i5FOrlcY1YIWNxRx5lC1CyVW1QQWtKUYaE68-yoLZag,19762
275
275
  warp/tests/test_compile_consts.py,sha256=by_7FTvoC-495n_XS49LBxNReqZ5YXS08EmjhOxs-54,6908
@@ -282,7 +282,7 @@ warp/tests/test_dlpack.py,sha256=H99Md6pJZDv2gdLh4omB6bYTf_pbNOnpHGfvEkpiRv8,238
282
282
  warp/tests/test_examples.py,sha256=pZ6FoJCpMLhlSUt1SvXsJdp7PHvTHNsDbAbx4Amj_wE,15612
283
283
  warp/tests/test_fabricarray.py,sha256=H186ayJZS95IGUZfzfwiOdEcqczXxN6gNmj9RvZPaPA,32340
284
284
  warp/tests/test_fast_math.py,sha256=8jETKu2zSAXLo8EZSnRMi2Ubmrd6JrpHUpppNruqMIw,2228
285
- warp/tests/test_fem.py,sha256=vn0iUv74HPsdCk7cm52tdO3fglkqK7Vi86_ERZYLFKw,64037
285
+ warp/tests/test_fem.py,sha256=_WEATA9VFA2TojAMM91ovsH4pelM9vE3DwDDOPJSYSo,64831
286
286
  warp/tests/test_fp16.py,sha256=g7N5oeKpx3QDnpOQKtyKIYv0eJEy0QwaEHXFCXxTXxE,3818
287
287
  warp/tests/test_func.py,sha256=pt3sBVnofb-ihX1WNf5Svektq2lw4OrLVDjuBaF7VXM,11799
288
288
  warp/tests/test_future_annotations.py,sha256=eC7VHcAOJ3fAgQsKPnrCq9oqkw3s2RbmcXe4rBaFEpQ,2208
@@ -314,7 +314,7 @@ warp/tests/test_mesh_query_aabb.py,sha256=ttfuEwO6eGyAhUAUt1_cM_0NjFSxKzAy8ZMzf7
314
314
  warp/tests/test_mesh_query_point.py,sha256=OBFhIDeA6XnzkAI69JTg4zqD5TAXeZUY0rXlgDsNIuk,27656
315
315
  warp/tests/test_mesh_query_ray.py,sha256=vWoPLcREGfVzEAQc60t1rE3gIYBYMDY8xGDMB1Q2RlQ,9193
316
316
  warp/tests/test_mlp.py,sha256=nnTMg-Oc_YndafdpyGE2zYZG3V9IdqfYS8LVGk4oUeE,7994
317
- warp/tests/test_model.py,sha256=78vx9B6xGMGTI1fEGkScHvrUyOmv_VSsUcQ620LT8Ag,7052
317
+ warp/tests/test_model.py,sha256=KZXE8_tx_cvGBZ_KTRwKaJTG3XNIkhavan4zYRaWTD4,7717
318
318
  warp/tests/test_module_hashing.py,sha256=ekTFrTEY8xtlOZErIk1bkDjYUg6jEiU0BAo5lOJlZPA,4799
319
319
  warp/tests/test_modules_lite.py,sha256=N3dUtTxzluaPF6rXmtYiSf8S27djAvPyj3ak-W_19H8,1152
320
320
  warp/tests/test_multigpu.py,sha256=ZPeZb1MA8pqQ_ERRllWbPKY_1Hr9AE9TN-vlka7IQls,5269
@@ -339,7 +339,7 @@ warp/tests/test_snippet.py,sha256=fBbGqlc6VJPmXRSF_J_UtrzCpM5XJHN_ejjgi2CMzOI,94
339
339
  warp/tests/test_sparse.py,sha256=jz9-9UtUh4n8r2uCI16Qt1Ju_WdXTAtMaz0Uk7vHcNo,20160
340
340
  warp/tests/test_spatial.py,sha256=kVfngbZLi-LDy4ooP1RMF0zb_VYmrRc8UksBXzsFQVU,76435
341
341
  warp/tests/test_special_values.py,sha256=5Ga45nJ6S7IPSVmeKUUia7CmWpYN9W-hnLPweUZIts4,14740
342
- warp/tests/test_static.py,sha256=ekzAeasoRIfiVvSKnGEmIzFGkr7-f5wiWuzQ3iZnUvE,13685
342
+ warp/tests/test_static.py,sha256=0kjwNf-m7uQ-TCpsqUiaXKSGLUsufqxHLBvoh6uQaL0,18489
343
343
  warp/tests/test_streams.py,sha256=3jJz2BZ9hIANceRII0OdLHu1rfLMJ1mJnJqEPyuz-h0,19750
344
344
  warp/tests/test_struct.py,sha256=vqHTX8vdUIn2adK4bdD9xXEYUtSUKL7hw3RA_IplqhQ,16990
345
345
  warp/tests/test_tape.py,sha256=AQ0dE5oWfKv2jDNCMOK5s9up0423uz2_M-WDPVi-fIU,5450
@@ -374,8 +374,8 @@ warp/thirdparty/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
374
374
  warp/thirdparty/appdirs.py,sha256=2UXPK-AkDGoN5APeqAMMYkkfgf3Q_aUEZxcfkIxlQn0,24254
375
375
  warp/thirdparty/dlpack.py,sha256=HYvNWIemrvxLDgQLRseerP8gqM87Ie7SVIX7p5xSM0o,4323
376
376
  warp/thirdparty/unittest_parallel.py,sha256=-FgbXrKiQ_RDj7YXYyhpRIPC3OmvJEnjvGkN99cqQA0,20888
377
- warp_lang-1.4.0.dist-info/LICENSE.md,sha256=Gq_TN0Xfat8Ftq2Rlvc31NgxdpLGVB-34kp-4eoeDV0,19265
378
- warp_lang-1.4.0.dist-info/METADATA,sha256=Jy807e9CHzSNOv8q94l726kC2p5OFG_-q0dg_c1c7UY,23286
379
- warp_lang-1.4.0.dist-info/WHEEL,sha256=AjtDPltU6Lu1vRLrU3cqhVnIsDSaO9geQd6pLjpNdDY,113
380
- warp_lang-1.4.0.dist-info/top_level.txt,sha256=8pupHORyKoiN_BYWlTmv5OFBWdhqpppiBYQV5KxgEvg,5
381
- warp_lang-1.4.0.dist-info/RECORD,,
377
+ warp_lang-1.4.1.dist-info/LICENSE.md,sha256=Gq_TN0Xfat8Ftq2Rlvc31NgxdpLGVB-34kp-4eoeDV0,19265
378
+ warp_lang-1.4.1.dist-info/METADATA,sha256=NT-TgzFD2kfdwrN4Q487Ze9BJ16dOnkjkftjsV3wflI,23286
379
+ warp_lang-1.4.1.dist-info/WHEEL,sha256=AjtDPltU6Lu1vRLrU3cqhVnIsDSaO9geQd6pLjpNdDY,113
380
+ warp_lang-1.4.1.dist-info/top_level.txt,sha256=8pupHORyKoiN_BYWlTmv5OFBWdhqpppiBYQV5KxgEvg,5
381
+ warp_lang-1.4.1.dist-info/RECORD,,