imt-ring 1.6.4__py3-none-any.whl → 1.6.6__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- {imt_ring-1.6.4.dist-info → imt_ring-1.6.6.dist-info}/METADATA +1 -1
- {imt_ring-1.6.4.dist-info → imt_ring-1.6.6.dist-info}/RECORD +5 -5
- ring/utils/utils.py +4 -3
- {imt_ring-1.6.4.dist-info → imt_ring-1.6.6.dist-info}/WHEEL +0 -0
- {imt_ring-1.6.4.dist-info → imt_ring-1.6.6.dist-info}/top_level.txt +0 -0
@@ -80,10 +80,10 @@ ring/utils/hdf5.py,sha256=BzXwVypZmEZeHVgeGZ78YYdi10NEQtnPhdrb8dQAXo0,5856
|
|
80
80
|
ring/utils/normalizer.py,sha256=67L2BU1MRsMT4pD41ta3JJMppLN0ozFmnwrmXDtnqrQ,1698
|
81
81
|
ring/utils/path.py,sha256=hAfSlqRi-ew536RnjDDM7IKapdMJc-EvhrR0Y-BCFWc,1265
|
82
82
|
ring/utils/randomize_sys.py,sha256=G_vBIo0OwQkXL2u0djwbaoaeb02C4LQCTNNloOYIU2M,3699
|
83
|
-
ring/utils/utils.py,sha256=
|
83
|
+
ring/utils/utils.py,sha256=oGC7kh19s5zvmnUvWy8B3fBl9loVU58ppz91osk2m3w,6550
|
84
84
|
ring/utils/register_gym_envs/__init__.py,sha256=PtPIRBQJ16339xZ9G9VpvqrvcGbQ_Pk_SUz4tQPa9nQ,94
|
85
85
|
ring/utils/register_gym_envs/saddle.py,sha256=tA5CyW_akSXyDm0xJ83CtOrUMVElH0f9vZtEDDJQalI,4422
|
86
|
-
imt_ring-1.6.
|
87
|
-
imt_ring-1.6.
|
88
|
-
imt_ring-1.6.
|
89
|
-
imt_ring-1.6.
|
86
|
+
imt_ring-1.6.6.dist-info/METADATA,sha256=izx_ZcizbG0DLoo7R2zzAbt-o-Zheh1hxPd7xTnxznY,3922
|
87
|
+
imt_ring-1.6.6.dist-info/WHEEL,sha256=Wyh-_nZ0DJYolHNn1_hMa4lM7uDedD_RGVwbmTjyItk,91
|
88
|
+
imt_ring-1.6.6.dist-info/top_level.txt,sha256=EiT790-lAyi8iwTzJArH3f2k77rwhDn00q-4PlmvDQo,5
|
89
|
+
imt_ring-1.6.6.dist-info/RECORD,,
|
ring/utils/utils.py
CHANGED
@@ -115,7 +115,7 @@ def pytree_deepcopy(tree):
|
|
115
115
|
"Recursivley copies a pytree."
|
116
116
|
if isinstance(tree, (int, float, jax.Array)):
|
117
117
|
return tree
|
118
|
-
elif isinstance(tree, np.ndarray):
|
118
|
+
elif isinstance(tree, np.ndarray) or np.isscalar(tree):
|
119
119
|
return tree.copy()
|
120
120
|
elif isinstance(tree, list):
|
121
121
|
return [pytree_deepcopy(ele) for ele in tree]
|
@@ -210,8 +210,9 @@ def replace_elements_w_nans(
|
|
210
210
|
if _is_nan(ele, i):
|
211
211
|
while True:
|
212
212
|
j = random.choice(include_elements)
|
213
|
-
|
214
|
-
|
213
|
+
ele_j = list_of_data[j]
|
214
|
+
if not _is_nan(ele_j, j):
|
215
|
+
ele = pytree_deepcopy(ele_j)
|
215
216
|
break
|
216
217
|
list_of_data_nonan.append(ele)
|
217
218
|
return list_of_data_nonan
|
File without changes
|
File without changes
|