labmate 0.8.1__tar.gz → 0.8.2__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.
- {labmate-0.8.1/labmate.egg-info → labmate-0.8.2}/PKG-INFO +1 -1
- {labmate-0.8.1 → labmate-0.8.2}/labmate/__config__.py +1 -1
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/acquisition_loop.py +20 -7
- {labmate-0.8.1 → labmate-0.8.2/labmate.egg-info}/PKG-INFO +1 -1
- {labmate-0.8.1 → labmate-0.8.2}/LICENCE +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/MANIFEST.in +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/README.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/about.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/acquisition_notebook.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/code/acquisition_loop.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/code/acquisition_manager.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/code/acquisition_notebook_manager.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/code/analysis_data.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/code/linting.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/code/parsing_config.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/acquisition_and_analysis_notebook.ipynb +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/aqm_simple_example.ipynb +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/files/cfg.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/files/dummy_config1.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/files/dummy_config2.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/files/dummy_config3.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/files/init_analyse.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/more/acquisition_and_analysis_notebook_with_magic.ipynb +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/more/h5nparray.ipynb +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/examples/more/loop_example.ipynb +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/h5nparray.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/index.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/releases/0.4.0.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/releases/0.5.0.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/releases/0.6.0.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/releases/0.6.1.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/releases/0.7.0.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/releases/0.8.0.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/releases/index.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/starting_guide/advanced_examples.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/starting_guide/fine_tune.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/starting_guide/first_steps.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/docs/starting_guide/install.md +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/acquisition_data.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/acquisition_manager.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/analysis_data.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/analysis_loop.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/config_file.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/custom_lint.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition/logger_setup.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition_notebook/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition_notebook/acquisition_analysis_manager.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition_notebook/display_widget.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/attrdict/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/attrdict/attrdict_class.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/display/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/display/buttons.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/display/html_output.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/display/links.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/display/main.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/display/platform_utils/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/display/platform_utils/windows_utils.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/parsing/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/parsing/brackets_score.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/parsing/parsed_value.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/parsing/saving.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/__init__.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/async_utils.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/autoreload.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/errors.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/file_read.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/lint.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/random_utils.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate/utils/title_parsing.py +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate.egg-info/SOURCES.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate.egg-info/dependency_links.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate.egg-info/requires.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/labmate.egg-info/top_level.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/requirements-docs.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/requirements.txt +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/setup.cfg +0 -0
- {labmate-0.8.1 → labmate-0.8.2}/setup.py +0 -0
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"""AcquisitionLoop class."""
|
|
2
|
+
|
|
2
3
|
from typing import Iterable, Iterator, Optional, Union, overload
|
|
3
4
|
|
|
4
5
|
import numpy as np
|
|
5
|
-
from dh5.dh5_types import SyncNp
|
|
6
6
|
from dh5 import DH5
|
|
7
|
+
from dh5.dh5_types import SyncNp
|
|
7
8
|
|
|
8
9
|
|
|
9
10
|
class AcquisitionLoop(DH5):
|
|
@@ -87,11 +88,17 @@ class AcquisitionLoop(DH5):
|
|
|
87
88
|
|
|
88
89
|
@overload
|
|
89
90
|
def __call__(
|
|
90
|
-
self,
|
|
91
|
+
self,
|
|
92
|
+
start: Union[int, float],
|
|
93
|
+
stop: Union[int, float],
|
|
94
|
+
step: Union[int, float],
|
|
95
|
+
/,
|
|
91
96
|
) -> Iterator:
|
|
92
97
|
"""Return np.arange(start, stop, step) given a start, stop and step."""
|
|
93
98
|
|
|
94
|
-
def __call__(
|
|
99
|
+
def __call__(
|
|
100
|
+
self, *args, iterable: Optional[Iterable] = None, **kwds
|
|
101
|
+
) -> Optional[Iterator]:
|
|
95
102
|
"""Append_data or arange.
|
|
96
103
|
|
|
97
104
|
If kwds are provided then is same as calling append_data(kwds),
|
|
@@ -108,7 +115,7 @@ class AcquisitionLoop(DH5):
|
|
|
108
115
|
return None
|
|
109
116
|
|
|
110
117
|
if iterable is None:
|
|
111
|
-
if isinstance(args[0], (int, float, np.int_, np.
|
|
118
|
+
if isinstance(args[0], (int, float, np.int_, np.floating)): # type: ignore
|
|
112
119
|
iterable = np.arange(*args)
|
|
113
120
|
else:
|
|
114
121
|
iterable = args[0]
|
|
@@ -171,7 +178,9 @@ class AcquisitionLoop(DH5):
|
|
|
171
178
|
self[key] = SyncNp(
|
|
172
179
|
np.pad(
|
|
173
180
|
self[key],
|
|
174
|
-
pad_width=tuple(
|
|
181
|
+
pad_width=tuple(
|
|
182
|
+
(0, i - j) for i, j in zip(key_shape, self[key].shape)
|
|
183
|
+
),
|
|
175
184
|
)
|
|
176
185
|
)
|
|
177
186
|
self[key][iteration] = value
|
|
@@ -194,7 +203,9 @@ class AcquisitionLoop(DH5):
|
|
|
194
203
|
):
|
|
195
204
|
if length is None:
|
|
196
205
|
if not hasattr(iterable, "__len__"):
|
|
197
|
-
raise TypeError(
|
|
206
|
+
raise TypeError(
|
|
207
|
+
"Iterable should has __len__ method or length should be provided"
|
|
208
|
+
)
|
|
198
209
|
length = len(iterable) # type: ignore
|
|
199
210
|
|
|
200
211
|
def loop_iter(array, length):
|
|
@@ -274,7 +285,9 @@ class AcquisitionLoop(DH5):
|
|
|
274
285
|
"""
|
|
275
286
|
if key is None:
|
|
276
287
|
if not self._save_indexes:
|
|
277
|
-
raise ValueError(
|
|
288
|
+
raise ValueError(
|
|
289
|
+
"As indexes are not saved with the Loop, key should be provided."
|
|
290
|
+
)
|
|
278
291
|
key = f"__index_{self._level}__"
|
|
279
292
|
|
|
280
293
|
iteration = tuple(self._iteration[: self._level])
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{labmate-0.8.1 → labmate-0.8.2}/labmate/acquisition_notebook/acquisition_analysis_manager.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|