reboost 0.9.0__py3-none-any.whl → 0.9.1__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.
- reboost/_version.py +2 -2
- reboost/core.py +19 -4
- {reboost-0.9.0.dist-info → reboost-0.9.1.dist-info}/METADATA +1 -1
- {reboost-0.9.0.dist-info → reboost-0.9.1.dist-info}/RECORD +8 -8
- {reboost-0.9.0.dist-info → reboost-0.9.1.dist-info}/WHEEL +1 -1
- {reboost-0.9.0.dist-info → reboost-0.9.1.dist-info}/entry_points.txt +0 -0
- {reboost-0.9.0.dist-info → reboost-0.9.1.dist-info}/licenses/LICENSE +0 -0
- {reboost-0.9.0.dist-info → reboost-0.9.1.dist-info}/top_level.txt +0 -0
reboost/_version.py
CHANGED
|
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
|
|
|
28
28
|
commit_id: COMMIT_ID
|
|
29
29
|
__commit_id__: COMMIT_ID
|
|
30
30
|
|
|
31
|
-
__version__ = version = '0.9.
|
|
32
|
-
__version_tuple__ = version_tuple = (0, 9,
|
|
31
|
+
__version__ = version = '0.9.1'
|
|
32
|
+
__version_tuple__ = version_tuple = (0, 9, 1)
|
|
33
33
|
|
|
34
34
|
__commit_id__ = commit_id = None
|
reboost/core.py
CHANGED
|
@@ -18,9 +18,18 @@ log = logging.getLogger(__name__)
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
def read_data_at_channel_as_ak(
|
|
21
|
-
channels: ak.Array,
|
|
21
|
+
channels: ak.Array,
|
|
22
|
+
rows: ak.Array,
|
|
23
|
+
file: str,
|
|
24
|
+
field: str,
|
|
25
|
+
group: str,
|
|
26
|
+
tab_map: dict[int, str],
|
|
27
|
+
with_units: bool = False,
|
|
22
28
|
) -> ak.Array:
|
|
23
|
-
r"""Read the data from a particular field to an
|
|
29
|
+
r"""Read the data from a particular field to an Awkward array.
|
|
30
|
+
|
|
31
|
+
This replaces the TCM like object defined by the channels and rows with the
|
|
32
|
+
corresponding data field.
|
|
24
33
|
|
|
25
34
|
Parameters
|
|
26
35
|
----------
|
|
@@ -68,7 +77,9 @@ def read_data_at_channel_as_ak(
|
|
|
68
77
|
tcm_rows = np.where(ak.flatten(channels == key))[0]
|
|
69
78
|
|
|
70
79
|
# read the data with sorted idx
|
|
71
|
-
data_ch = lh5.read(f"{group}/{tab_name}/{field}", file, idx=idx[arg_idx])
|
|
80
|
+
data_ch = lh5.read(f"{group}/{tab_name}/{field}", file, idx=idx[arg_idx])
|
|
81
|
+
units = data_ch.attrs.get("units", None)
|
|
82
|
+
data_ch = data_ch.view_as("ak")
|
|
72
83
|
|
|
73
84
|
# sort back to order for tcm
|
|
74
85
|
data_ch = data_ch[np.argsort(arg_idx)]
|
|
@@ -85,8 +96,12 @@ def read_data_at_channel_as_ak(
|
|
|
85
96
|
|
|
86
97
|
# sort the final data
|
|
87
98
|
data_flat = data_flat[np.argsort(tcm_rows_full)]
|
|
99
|
+
data_unflat = ak.unflatten(data_flat, reorder)
|
|
100
|
+
|
|
101
|
+
if with_units and units is not None:
|
|
102
|
+
return ak.with_parameter(data_unflat, "units", units)
|
|
88
103
|
|
|
89
|
-
return
|
|
104
|
+
return data_unflat
|
|
90
105
|
|
|
91
106
|
|
|
92
107
|
def evaluate_output_column(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: reboost
|
|
3
|
-
Version: 0.9.
|
|
3
|
+
Version: 0.9.1
|
|
4
4
|
Summary: New LEGEND Monte-Carlo simulation post-processing
|
|
5
5
|
Author-email: Manuel Huber <info@manuelhu.de>, Toby Dixon <toby.dixon.23@ucl.ac.uk>, Luigi Pertoldi <gipert@pm.me>
|
|
6
6
|
Maintainer: The LEGEND Collaboration
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
reboost/__init__.py,sha256=VZz9uo7i2jgAx8Zi15SptLZnE_qcnGuNWwqkD3rYHFA,278
|
|
2
2
|
reboost/__main__.py,sha256=42koSxY2st4mMIRSAnKz06nP5HppMPxBVFf2jaHljGs,95
|
|
3
|
-
reboost/_version.py,sha256=
|
|
3
|
+
reboost/_version.py,sha256=LwGndsRSpclYq-j3wgRr2nzOXwUYj0Jtg7Kof7R0BEw,704
|
|
4
4
|
reboost/build_evt.py,sha256=VXIfK_pfe_Cgym6gI8dESwONZi-v_4fll0Pn09vePQY,3767
|
|
5
5
|
reboost/build_glm.py,sha256=IerSLQfe51ZO7CQP2kmfPnOIVaDtcfw3byOM02Vaz6o,9472
|
|
6
6
|
reboost/build_hit.py,sha256=N_nxvH69SvILVNmyvVfhQwQdD_PDW8tlsqj2ciO5nKE,17409
|
|
7
7
|
reboost/cli.py,sha256=68EzKiWTHJ2u1RILUv7IX9HaVq6nTTM80_W_MUnWRe4,6382
|
|
8
|
-
reboost/core.py,sha256=
|
|
8
|
+
reboost/core.py,sha256=NtCDTZ6QQyFhj0BiGuIXBu6WBSrrY7C4GTfaw1u5K-w,15501
|
|
9
9
|
reboost/iterator.py,sha256=qlEqRv5qOh8eIs-dyVOLYTvH-ZpQDx9fLckpcAdtWjs,6975
|
|
10
10
|
reboost/log_utils.py,sha256=VqS_9OC5NeNU3jcowVOBB0NJ6ssYvNWnirEY-JVduEA,766
|
|
11
11
|
reboost/profile.py,sha256=EOTmjmS8Rm_nYgBWNh6Rntl2XDsxdyed7yEdWtsZEeg,2598
|
|
@@ -36,9 +36,9 @@ reboost/shape/group.py,sha256=gOCYgir2gZqmW1JXtbNRPlQqP0gmUcbe7RVb9CbY1pU,5540
|
|
|
36
36
|
reboost/shape/reduction.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
37
37
|
reboost/spms/__init__.py,sha256=8I6WT8i_kUPqEDnSD0aCf6A26cjKjQQZSNrvwZ3o-Ac,415
|
|
38
38
|
reboost/spms/pe.py,sha256=LwqrK1HOZWzGcNZnntaqI6r4rnDww4KW9Mao4xLFbDE,8226
|
|
39
|
-
reboost-0.9.
|
|
40
|
-
reboost-0.9.
|
|
41
|
-
reboost-0.9.
|
|
42
|
-
reboost-0.9.
|
|
43
|
-
reboost-0.9.
|
|
44
|
-
reboost-0.9.
|
|
39
|
+
reboost-0.9.1.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
|
40
|
+
reboost-0.9.1.dist-info/METADATA,sha256=nW1jNoPEgO6PPTKtW0U_eDQ8ua35E3MVgumUrkYb1Y4,3877
|
|
41
|
+
reboost-0.9.1.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
|
|
42
|
+
reboost-0.9.1.dist-info/entry_points.txt,sha256=DxhD6BidSWNot9BrejHJjQ7RRLmrMaBIl52T75oWTwM,93
|
|
43
|
+
reboost-0.9.1.dist-info/top_level.txt,sha256=q-IBsDepaY_AbzbRmQoW8EZrITXRVawVnNrB-_zyXZs,8
|
|
44
|
+
reboost-0.9.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|