ezmsg-neo 0.1__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.
- ezmsg_neo-0.1/.github/workflows/python-publish-ezmsg-neo.yml +26 -0
- ezmsg_neo-0.1/.github/workflows/python-tests.yml +41 -0
- ezmsg_neo-0.1/.gitignore +164 -0
- ezmsg_neo-0.1/.python-version +1 -0
- ezmsg_neo-0.1/LICENSE +21 -0
- ezmsg_neo-0.1/PKG-INFO +35 -0
- ezmsg_neo-0.1/README.md +21 -0
- ezmsg_neo-0.1/pyproject.toml +39 -0
- ezmsg_neo-0.1/src/ezmsg/neo/__init__.py +1 -0
- ezmsg_neo-0.1/src/ezmsg/neo/__version__.py +16 -0
- ezmsg_neo-0.1/src/ezmsg/neo/py.typed +0 -0
- ezmsg_neo-0.1/src/ezmsg/neo/source.py +241 -0
- ezmsg_neo-0.1/src/ezmsg/neo/util.py +21 -0
- ezmsg_neo-0.1/tests/test_neo_source.py +20 -0
- ezmsg_neo-0.1/uv.lock +217 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
name: Upload Python Package - ezmsg-neo
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
workflow_dispatch:
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
build:
|
|
10
|
+
name: build and upload release to PyPI
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
environment: "release"
|
|
13
|
+
permissions:
|
|
14
|
+
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
|
|
15
|
+
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
|
|
19
|
+
- name: Install uv
|
|
20
|
+
uses: astral-sh/setup-uv@v2
|
|
21
|
+
|
|
22
|
+
- name: Build Package
|
|
23
|
+
run: uv build
|
|
24
|
+
|
|
25
|
+
- name: Publish package distributions to PyPI
|
|
26
|
+
run: uv publish
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
name: Test package
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
workflow_dispatch:
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
build:
|
|
12
|
+
strategy:
|
|
13
|
+
matrix:
|
|
14
|
+
python-version: [3.9, "3.10", "3.11", "3.12"]
|
|
15
|
+
os:
|
|
16
|
+
- "ubuntu-latest"
|
|
17
|
+
- "windows-latest"
|
|
18
|
+
- "macos-latest"
|
|
19
|
+
runs-on: ${{matrix.os}}
|
|
20
|
+
|
|
21
|
+
steps:
|
|
22
|
+
- uses: actions/checkout@v4
|
|
23
|
+
|
|
24
|
+
- name: Install uv
|
|
25
|
+
uses: astral-sh/setup-uv@v2
|
|
26
|
+
with:
|
|
27
|
+
enable-cache: true
|
|
28
|
+
cache-dependency-glob: "uv.lock"
|
|
29
|
+
|
|
30
|
+
- name: Set up Python ${{ matrix.python-version }}
|
|
31
|
+
run: uv python install ${{ matrix.python-version }}
|
|
32
|
+
|
|
33
|
+
- name: Install the project
|
|
34
|
+
run: uv sync --all-extras --dev
|
|
35
|
+
|
|
36
|
+
- name: Lint
|
|
37
|
+
run:
|
|
38
|
+
uv tool run ruff check --output-format=github src
|
|
39
|
+
|
|
40
|
+
# - name: Run tests
|
|
41
|
+
# run: uv run pytest tests
|
ezmsg_neo-0.1/.gitignore
ADDED
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py,cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
#Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# poetry
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
102
|
+
#poetry.lock
|
|
103
|
+
|
|
104
|
+
# pdm
|
|
105
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
106
|
+
#pdm.lock
|
|
107
|
+
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
|
108
|
+
# in version control.
|
|
109
|
+
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
|
|
110
|
+
.pdm.toml
|
|
111
|
+
.pdm-python
|
|
112
|
+
.pdm-build/
|
|
113
|
+
|
|
114
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
115
|
+
__pypackages__/
|
|
116
|
+
|
|
117
|
+
# Celery stuff
|
|
118
|
+
celerybeat-schedule
|
|
119
|
+
celerybeat.pid
|
|
120
|
+
|
|
121
|
+
# SageMath parsed files
|
|
122
|
+
*.sage.py
|
|
123
|
+
|
|
124
|
+
# Environments
|
|
125
|
+
.env
|
|
126
|
+
.venv
|
|
127
|
+
env/
|
|
128
|
+
venv/
|
|
129
|
+
ENV/
|
|
130
|
+
env.bak/
|
|
131
|
+
venv.bak/
|
|
132
|
+
|
|
133
|
+
# Spyder project settings
|
|
134
|
+
.spyderproject
|
|
135
|
+
.spyproject
|
|
136
|
+
|
|
137
|
+
# Rope project settings
|
|
138
|
+
.ropeproject
|
|
139
|
+
|
|
140
|
+
# mkdocs documentation
|
|
141
|
+
/site
|
|
142
|
+
|
|
143
|
+
# mypy
|
|
144
|
+
.mypy_cache/
|
|
145
|
+
.dmypy.json
|
|
146
|
+
dmypy.json
|
|
147
|
+
|
|
148
|
+
# Pyre type checker
|
|
149
|
+
.pyre/
|
|
150
|
+
|
|
151
|
+
# pytype static type analyzer
|
|
152
|
+
.pytype/
|
|
153
|
+
|
|
154
|
+
# Cython debug symbols
|
|
155
|
+
cython_debug/
|
|
156
|
+
|
|
157
|
+
# PyCharm
|
|
158
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
159
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
160
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
161
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
162
|
+
#.idea/
|
|
163
|
+
|
|
164
|
+
src/ezmsg/neo/__version__.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.9
|
ezmsg_neo-0.1/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 ezmsg-org
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
ezmsg_neo-0.1/PKG-INFO
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
Metadata-Version: 2.3
|
|
2
|
+
Name: ezmsg-neo
|
|
3
|
+
Version: 0.1
|
|
4
|
+
Summary: Load and stream data from neo files into ezmsg.
|
|
5
|
+
Author-email: Chadwick Boulay <chadwick.boulay@gmail.com>
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
License-File: LICENSE
|
|
8
|
+
Requires-Python: >=3.9
|
|
9
|
+
Requires-Dist: ezmsg>=3.5.0
|
|
10
|
+
Requires-Dist: neo>=0.13.3
|
|
11
|
+
Provides-Extra: tests
|
|
12
|
+
Requires-Dist: pytest>=8.3.3; extra == 'tests'
|
|
13
|
+
Description-Content-Type: text/markdown
|
|
14
|
+
|
|
15
|
+
# ezmsg-neo
|
|
16
|
+
|
|
17
|
+
Load and stream data from [neo](https://github.com/NeuralEnsemble/python-neo) files into [ezmsg](https://github.com/iscoe/ezmsg).
|
|
18
|
+
|
|
19
|
+
## Installation
|
|
20
|
+
|
|
21
|
+
TODO: `pip install ezmsg-neo`
|
|
22
|
+
|
|
23
|
+
For now `pip install ezmsg-neo@git+https://github.com/ezmsg-org/ezmsg-neo`
|
|
24
|
+
|
|
25
|
+
## Dependencies
|
|
26
|
+
* `ezmsg`
|
|
27
|
+
* `neo`
|
|
28
|
+
|
|
29
|
+
## Setup (Development)
|
|
30
|
+
|
|
31
|
+
1. Clone this repo
|
|
32
|
+
2. `uv init`
|
|
33
|
+
3. ezmsg-neo modules are available under `import ezmsg.neo`
|
|
34
|
+
|
|
35
|
+
TODO: See the `examples` folder for more details.
|
ezmsg_neo-0.1/README.md
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# ezmsg-neo
|
|
2
|
+
|
|
3
|
+
Load and stream data from [neo](https://github.com/NeuralEnsemble/python-neo) files into [ezmsg](https://github.com/iscoe/ezmsg).
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
TODO: `pip install ezmsg-neo`
|
|
8
|
+
|
|
9
|
+
For now `pip install ezmsg-neo@git+https://github.com/ezmsg-org/ezmsg-neo`
|
|
10
|
+
|
|
11
|
+
## Dependencies
|
|
12
|
+
* `ezmsg`
|
|
13
|
+
* `neo`
|
|
14
|
+
|
|
15
|
+
## Setup (Development)
|
|
16
|
+
|
|
17
|
+
1. Clone this repo
|
|
18
|
+
2. `uv init`
|
|
19
|
+
3. ezmsg-neo modules are available under `import ezmsg.neo`
|
|
20
|
+
|
|
21
|
+
TODO: See the `examples` folder for more details.
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "ezmsg-neo"
|
|
3
|
+
description = "Load and stream data from neo files into ezmsg."
|
|
4
|
+
authors = [
|
|
5
|
+
{ name = "Chadwick Boulay", email = "chadwick.boulay@gmail.com" },
|
|
6
|
+
]
|
|
7
|
+
license = "MIT"
|
|
8
|
+
readme = "README.md"
|
|
9
|
+
requires-python = ">=3.9"
|
|
10
|
+
dependencies = [
|
|
11
|
+
"ezmsg>=3.5.0",
|
|
12
|
+
"neo>=0.13.3",
|
|
13
|
+
]
|
|
14
|
+
dynamic = ["version"]
|
|
15
|
+
|
|
16
|
+
[project.optional-dependencies]
|
|
17
|
+
tests = [
|
|
18
|
+
"pytest>=8.3.3",
|
|
19
|
+
]
|
|
20
|
+
|
|
21
|
+
[build-system]
|
|
22
|
+
requires = ["hatchling", "hatch-vcs"]
|
|
23
|
+
build-backend = "hatchling.build"
|
|
24
|
+
|
|
25
|
+
[tool.hatch.version]
|
|
26
|
+
source = "vcs"
|
|
27
|
+
|
|
28
|
+
[tool.hatch.build.hooks.vcs]
|
|
29
|
+
version-file = "src/ezmsg/neo/__version__.py"
|
|
30
|
+
|
|
31
|
+
[tool.hatch.build.targets.wheel]
|
|
32
|
+
packages = ["src/ezmsg"]
|
|
33
|
+
|
|
34
|
+
[tool.uv]
|
|
35
|
+
dev-dependencies = [
|
|
36
|
+
"ruff>=0.6.8",
|
|
37
|
+
]
|
|
38
|
+
|
|
39
|
+
[tool.uv.sources]
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
from .__version__ import __version__ as __version__
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# file generated by setuptools_scm
|
|
2
|
+
# don't change, don't track in version control
|
|
3
|
+
TYPE_CHECKING = False
|
|
4
|
+
if TYPE_CHECKING:
|
|
5
|
+
from typing import Tuple, Union
|
|
6
|
+
VERSION_TUPLE = Tuple[Union[int, str], ...]
|
|
7
|
+
else:
|
|
8
|
+
VERSION_TUPLE = object
|
|
9
|
+
|
|
10
|
+
version: str
|
|
11
|
+
__version__: str
|
|
12
|
+
__version_tuple__: VERSION_TUPLE
|
|
13
|
+
version_tuple: VERSION_TUPLE
|
|
14
|
+
|
|
15
|
+
__version__ = version = '0.1'
|
|
16
|
+
__version_tuple__ = version_tuple = (0, 1)
|
|
File without changes
|
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
import asyncio
|
|
2
|
+
from collections import deque
|
|
3
|
+
from dataclasses import replace
|
|
4
|
+
import os
|
|
5
|
+
from pathlib import Path
|
|
6
|
+
import time
|
|
7
|
+
import typing
|
|
8
|
+
|
|
9
|
+
import ezmsg.core as ez
|
|
10
|
+
|
|
11
|
+
from .util import AxisArray # This one has labels field.
|
|
12
|
+
from ezmsg.util.generator import GenState
|
|
13
|
+
import neo.rawio.baserawio
|
|
14
|
+
import numpy as np
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
class NeoIteratorSettings(ez.Settings):
|
|
18
|
+
"""Settings for :obj:`NeoIterator`."""
|
|
19
|
+
|
|
20
|
+
filepath: os.PathLike
|
|
21
|
+
chunk_dur: float = 0.1
|
|
22
|
+
self_terminating: bool = True
|
|
23
|
+
t_offset: typing.Optional[float] = None
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class NeoIterator:
|
|
27
|
+
def __init__(self, settings: NeoIteratorSettings):
|
|
28
|
+
self._settings = settings
|
|
29
|
+
self._reader: typing.Optional[neo.rawio.baserawio.BaseRawIO] = None
|
|
30
|
+
self._playback_state: typing.Optional[dict] = None
|
|
31
|
+
self._reset()
|
|
32
|
+
|
|
33
|
+
def _reset(self):
|
|
34
|
+
self._playback_state = {
|
|
35
|
+
"t_offset": self._settings.t_offset
|
|
36
|
+
if self._settings.t_offset is not None
|
|
37
|
+
else time.time(),
|
|
38
|
+
"t_start": np.inf,
|
|
39
|
+
"chunk_ix": 0,
|
|
40
|
+
"msg_queue": deque(),
|
|
41
|
+
"streams": {},
|
|
42
|
+
}
|
|
43
|
+
self._preload()
|
|
44
|
+
|
|
45
|
+
def _preload(self):
|
|
46
|
+
fpath = Path(self._settings.filepath)
|
|
47
|
+
|
|
48
|
+
if not fpath.exists():
|
|
49
|
+
raise FileNotFoundError(f"File not found: {fpath}")
|
|
50
|
+
|
|
51
|
+
if fpath.suffix == ".vhdr":
|
|
52
|
+
from neo.rawio import BrainVisionRawIO as RawIO
|
|
53
|
+
else:
|
|
54
|
+
raise ValueError(f"Unsupported file type: {fpath.suffix}")
|
|
55
|
+
|
|
56
|
+
self._reader = RawIO(filename=str(fpath))
|
|
57
|
+
self._reader.parse_header()
|
|
58
|
+
|
|
59
|
+
nb_block = self._reader.block_count()
|
|
60
|
+
if nb_block > 1:
|
|
61
|
+
raise NotImplementedError("Only single-block files are supported.")
|
|
62
|
+
nb_seg = [self._reader.segment_count(_) for _ in range(nb_block)][0]
|
|
63
|
+
if nb_seg > 1:
|
|
64
|
+
raise NotImplementedError("Only single-segment files are supported.")
|
|
65
|
+
nb_sig_streams = self._reader.signal_streams_count()
|
|
66
|
+
|
|
67
|
+
t_stop = -np.inf
|
|
68
|
+
|
|
69
|
+
# Fill out metadata for analogsignal streams
|
|
70
|
+
for strm_ix in range(nb_sig_streams):
|
|
71
|
+
t_start = self._reader.get_signal_t_start(0, 0, strm_ix)
|
|
72
|
+
self._playback_state["t_start"] = min(
|
|
73
|
+
self._playback_state["t_start"], t_start
|
|
74
|
+
)
|
|
75
|
+
nb_chans = self._reader.signal_channels_count(strm_ix)
|
|
76
|
+
fs = self._reader.get_signal_sampling_rate(strm_ix)
|
|
77
|
+
nb_samps = self._reader.get_signal_size(0, 0, strm_ix)
|
|
78
|
+
t_stop = max(t_stop, t_start + nb_samps / fs)
|
|
79
|
+
chan_struct_arr = self._reader.header["signal_channels"]
|
|
80
|
+
key = self._reader.header["signal_streams"][strm_ix]["name"]
|
|
81
|
+
template = AxisArray(
|
|
82
|
+
data=np.zeros((0, nb_chans), dtype=float),
|
|
83
|
+
dims=["time", "ch"],
|
|
84
|
+
axes={
|
|
85
|
+
"time": AxisArray.Axis.TimeAxis(fs=fs, offset=0.0),
|
|
86
|
+
"ch": AxisArray.Axis(labels=chan_struct_arr["name"].tolist()),
|
|
87
|
+
},
|
|
88
|
+
key=key,
|
|
89
|
+
)
|
|
90
|
+
self._playback_state["streams"][key] = {
|
|
91
|
+
"idx": strm_ix,
|
|
92
|
+
"type": "analogsignal",
|
|
93
|
+
"t_start": t_start,
|
|
94
|
+
"template": template,
|
|
95
|
+
"prev_samp": 0,
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
# Fill out metadata for event streams
|
|
99
|
+
nb_event_channel = self._reader.event_channels_count()
|
|
100
|
+
if nb_event_channel > 0:
|
|
101
|
+
# TODO: Event should probably use SampleTriggerMessage
|
|
102
|
+
self._playback_state["streams"]["events"] = {
|
|
103
|
+
"type": "event",
|
|
104
|
+
"nchan": nb_event_channel,
|
|
105
|
+
"template": AxisArray(
|
|
106
|
+
data=np.array([""]),
|
|
107
|
+
dims=["time"],
|
|
108
|
+
axes={"time": AxisArray.Axis.TimeAxis(fs=1, offset=0.0)},
|
|
109
|
+
key="events",
|
|
110
|
+
),
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
# TODO: Add support for spiketrain streams
|
|
114
|
+
# nb_unit = self._reader.spike_channels_count()
|
|
115
|
+
|
|
116
|
+
t_elapsed = t_stop - self._playback_state["t_start"]
|
|
117
|
+
self._playback_state["n_chunks"] = int(
|
|
118
|
+
np.ceil(t_elapsed / self._settings.chunk_dur)
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
def __iter__(self):
|
|
122
|
+
self._reset()
|
|
123
|
+
return self
|
|
124
|
+
|
|
125
|
+
def _chunk_step(self):
|
|
126
|
+
state = self._playback_state
|
|
127
|
+
t_range = (
|
|
128
|
+
state["chunk_ix"] * self._settings.chunk_dur,
|
|
129
|
+
(state["chunk_ix"] + 1) * self._settings.chunk_dur,
|
|
130
|
+
)
|
|
131
|
+
|
|
132
|
+
for key, strm in state["streams"].items():
|
|
133
|
+
if strm["type"] == "analogsignal":
|
|
134
|
+
# Fetch data from last_idx to next_idx = next_time * fs
|
|
135
|
+
fs = 1 / strm["template"].axes["time"].gain
|
|
136
|
+
prev_samp = strm["prev_samp"]
|
|
137
|
+
next_samp = max(0, int((t_range[1] - strm["t_start"]) * fs))
|
|
138
|
+
dat = self._reader.get_analogsignal_chunk(
|
|
139
|
+
seg_index=0,
|
|
140
|
+
stream_index=strm["idx"],
|
|
141
|
+
i_start=prev_samp,
|
|
142
|
+
i_stop=next_samp,
|
|
143
|
+
)
|
|
144
|
+
if dat.size:
|
|
145
|
+
dat = self._reader.rescale_signal_raw_to_float(dat, dtype=float)
|
|
146
|
+
msg = replace(
|
|
147
|
+
strm["template"],
|
|
148
|
+
data=dat,
|
|
149
|
+
axes={
|
|
150
|
+
"ch": strm["template"].axes["ch"],
|
|
151
|
+
"time": replace(
|
|
152
|
+
strm["template"].axes["time"],
|
|
153
|
+
offset=t_range[0] + state["t_offset"],
|
|
154
|
+
),
|
|
155
|
+
},
|
|
156
|
+
)
|
|
157
|
+
state["msg_queue"].append(msg)
|
|
158
|
+
strm["prev_samp"] = next_samp
|
|
159
|
+
elif strm["type"] == "event":
|
|
160
|
+
# TODO: Event should probably use SampleTriggerMessage
|
|
161
|
+
for ev_ch_ix in range(strm["nchan"]):
|
|
162
|
+
ev_timestamps, ev_durations, ev_labels = (
|
|
163
|
+
self._reader.get_event_timestamps(
|
|
164
|
+
block_index=0,
|
|
165
|
+
seg_index=0,
|
|
166
|
+
event_channel_index=ev_ch_ix,
|
|
167
|
+
t_start=t_range[0],
|
|
168
|
+
t_stop=t_range[1],
|
|
169
|
+
)
|
|
170
|
+
)
|
|
171
|
+
ev_times = self._reader.rescale_event_timestamp(
|
|
172
|
+
ev_timestamps, dtype=float
|
|
173
|
+
)
|
|
174
|
+
for ev_t, ev_l in zip(ev_times, ev_labels):
|
|
175
|
+
msg = replace(
|
|
176
|
+
strm["template"],
|
|
177
|
+
data=np.array(
|
|
178
|
+
[ev_l],
|
|
179
|
+
),
|
|
180
|
+
axes={
|
|
181
|
+
"time": replace(
|
|
182
|
+
strm["template"].axes["time"],
|
|
183
|
+
offset=ev_t + state["t_offset"],
|
|
184
|
+
),
|
|
185
|
+
},
|
|
186
|
+
)
|
|
187
|
+
state["msg_queue"].append(msg)
|
|
188
|
+
|
|
189
|
+
else:
|
|
190
|
+
# TODO: spiketrain
|
|
191
|
+
# spike_timestamps = self._reader.get_spike_timestamps(block_index=0, seg_index=0, spike_channel_index=0,
|
|
192
|
+
# t_start=0, t_stop=10)
|
|
193
|
+
# spike_timestamps
|
|
194
|
+
# spike_times = self._reader.rescale_spike_timestamp(spike_timestamps, dtype='float64')
|
|
195
|
+
# raw_waveforms = reader.get_spike_raw_waveforms(block_index=0, seg_index=0, spike_channel_index=0,
|
|
196
|
+
# t_start=0, t_stop=10)
|
|
197
|
+
# float_waveforms = reader.rescale_waveforms_to_float(raw_waveforms, dtype='float32', spike_channel_index=0)
|
|
198
|
+
raise NotImplementedError(f"Unsupported stream type: {strm['type']}")
|
|
199
|
+
|
|
200
|
+
state["chunk_ix"] += 1
|
|
201
|
+
|
|
202
|
+
def __next__(self) -> AxisArray:
|
|
203
|
+
state = self._playback_state
|
|
204
|
+
if not state["msg_queue"]:
|
|
205
|
+
if state["chunk_ix"] >= state["n_chunks"]:
|
|
206
|
+
# TODO Close file
|
|
207
|
+
raise StopIteration
|
|
208
|
+
self._chunk_step()
|
|
209
|
+
|
|
210
|
+
if not state["msg_queue"]:
|
|
211
|
+
raise StopIteration
|
|
212
|
+
|
|
213
|
+
return state["msg_queue"].popleft()
|
|
214
|
+
|
|
215
|
+
|
|
216
|
+
class NeoIteratorUnit(ez.Unit):
|
|
217
|
+
STATE = GenState
|
|
218
|
+
SETTINGS = NeoIteratorSettings
|
|
219
|
+
|
|
220
|
+
OUTPUT_SIGNAL = ez.OutputStream(AxisArray)
|
|
221
|
+
OUTPUT_TERM = ez.OutputStream(typing.Any)
|
|
222
|
+
|
|
223
|
+
def initialize(self) -> None:
|
|
224
|
+
self.construct_generator()
|
|
225
|
+
|
|
226
|
+
def construct_generator(self):
|
|
227
|
+
self.STATE.gen = NeoIterator(
|
|
228
|
+
settings=self.SETTINGS,
|
|
229
|
+
)
|
|
230
|
+
|
|
231
|
+
@ez.publisher(OUTPUT_SIGNAL)
|
|
232
|
+
async def pub_chunk(self) -> typing.AsyncGenerator:
|
|
233
|
+
for msg in self.STATE.gen:
|
|
234
|
+
# TODO: Direct msg to OUTPUT_TRIGGER if type is SampleTriggerMessage
|
|
235
|
+
yield self.OUTPUT_SIGNAL, msg
|
|
236
|
+
await asyncio.sleep(0)
|
|
237
|
+
|
|
238
|
+
ez.logger.debug(f"File ({self.SETTINGS.filepath}) exhausted.")
|
|
239
|
+
if self.SETTINGS.self_terminating:
|
|
240
|
+
raise ez.NormalTermination
|
|
241
|
+
yield self.OUTPUT_TERM, ez.Flag
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
from dataclasses import dataclass, field
|
|
2
|
+
import typing
|
|
3
|
+
|
|
4
|
+
from ezmsg.util.messages.axisarray import AxisArray
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
@dataclass
|
|
8
|
+
class CustomAxis(AxisArray.Axis):
|
|
9
|
+
labels: typing.List[str] = field(default_factory=lambda: [])
|
|
10
|
+
|
|
11
|
+
@classmethod
|
|
12
|
+
def SpaceAxis(
|
|
13
|
+
cls,
|
|
14
|
+
labels: typing.List[str],
|
|
15
|
+
# locs: typing.Optional[npt.NDArray] = None
|
|
16
|
+
):
|
|
17
|
+
return cls(unit="mm", labels=labels)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
# Monkey-patch AxisArray with our customized Axis
|
|
21
|
+
AxisArray.Axis = CustomAxis
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# import os
|
|
2
|
+
# from pathlib import Path
|
|
3
|
+
|
|
4
|
+
from ezmsg.neo.source import NeoIterator, NeoIteratorSettings
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
def test_brainvision_playback():
|
|
8
|
+
|
|
9
|
+
source_path = None # TODO - web source.
|
|
10
|
+
settings = NeoIteratorSettings(filepath=source_path)
|
|
11
|
+
neo_iter = NeoIterator(settings)
|
|
12
|
+
|
|
13
|
+
data_msg_count = 0
|
|
14
|
+
for msg in neo_iter:
|
|
15
|
+
if msg.key == "events":
|
|
16
|
+
print(msg)
|
|
17
|
+
else:
|
|
18
|
+
data_msg_count += 1
|
|
19
|
+
|
|
20
|
+
print(f"Data messages: {data_msg_count}")
|
ezmsg_neo-0.1/uv.lock
ADDED
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
version = 1
|
|
2
|
+
requires-python = ">=3.9"
|
|
3
|
+
|
|
4
|
+
[[package]]
|
|
5
|
+
name = "colorama"
|
|
6
|
+
version = "0.4.6"
|
|
7
|
+
source = { registry = "https://pypi.org/simple" }
|
|
8
|
+
sdist = { url = "https://files.pythonhosted.org/packages/d8/53/6f443c9a4a8358a93a6792e2acffb9d9d5cb0a5cfd8802644b7b1c9a02e4/colorama-0.4.6.tar.gz", hash = "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44", size = 27697 }
|
|
9
|
+
wheels = [
|
|
10
|
+
{ url = "https://files.pythonhosted.org/packages/d1/d6/3965ed04c63042e047cb6a3e6ed1a63a35087b6a609aa3a15ed8ac56c221/colorama-0.4.6-py2.py3-none-any.whl", hash = "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6", size = 25335 },
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
[[package]]
|
|
14
|
+
name = "exceptiongroup"
|
|
15
|
+
version = "1.2.2"
|
|
16
|
+
source = { registry = "https://pypi.org/simple" }
|
|
17
|
+
sdist = { url = "https://files.pythonhosted.org/packages/09/35/2495c4ac46b980e4ca1f6ad6db102322ef3ad2410b79fdde159a4b0f3b92/exceptiongroup-1.2.2.tar.gz", hash = "sha256:47c2edf7c6738fafb49fd34290706d1a1a2f4d1c6df275526b62cbb4aa5393cc", size = 28883 }
|
|
18
|
+
wheels = [
|
|
19
|
+
{ url = "https://files.pythonhosted.org/packages/02/cc/b7e31358aac6ed1ef2bb790a9746ac2c69bcb3c8588b41616914eb106eaf/exceptiongroup-1.2.2-py3-none-any.whl", hash = "sha256:3111b9d131c238bec2f8f516e123e14ba243563fb135d3fe885990585aa7795b", size = 16453 },
|
|
20
|
+
]
|
|
21
|
+
|
|
22
|
+
[[package]]
|
|
23
|
+
name = "ezmsg"
|
|
24
|
+
version = "3.5.0"
|
|
25
|
+
source = { registry = "https://pypi.org/simple" }
|
|
26
|
+
dependencies = [
|
|
27
|
+
{ name = "typing-extensions" },
|
|
28
|
+
]
|
|
29
|
+
sdist = { url = "https://files.pythonhosted.org/packages/48/a7/7e228053869f41c9e71d7fca1111fffdb3716ec8307de1aca1b57c845d9d/ezmsg-3.5.0.tar.gz", hash = "sha256:1b08972f1231299b7148d383519374113e5b44e9eaf7bf287baa60be40aa21cd", size = 136358 }
|
|
30
|
+
wheels = [
|
|
31
|
+
{ url = "https://files.pythonhosted.org/packages/92/53/42cfc9f0c5f1dfb4715b5e5dfe6abc279c4e83814488d1d5ecd361ec527b/ezmsg-3.5.0-py3-none-any.whl", hash = "sha256:f37864d46ecf5f75de5d8a89253f8c19563ecd5fe8beeddf2b334ef000319ff9", size = 67621 },
|
|
32
|
+
]
|
|
33
|
+
|
|
34
|
+
[[package]]
|
|
35
|
+
name = "ezmsg-neo"
|
|
36
|
+
version = "0.1.dev3+g536ded8.d20240926"
|
|
37
|
+
source = { editable = "." }
|
|
38
|
+
dependencies = [
|
|
39
|
+
{ name = "ezmsg" },
|
|
40
|
+
{ name = "neo" },
|
|
41
|
+
]
|
|
42
|
+
|
|
43
|
+
[package.optional-dependencies]
|
|
44
|
+
tests = [
|
|
45
|
+
{ name = "pytest" },
|
|
46
|
+
]
|
|
47
|
+
|
|
48
|
+
[package.dev-dependencies]
|
|
49
|
+
dev = [
|
|
50
|
+
{ name = "ruff" },
|
|
51
|
+
]
|
|
52
|
+
|
|
53
|
+
[package.metadata]
|
|
54
|
+
requires-dist = [
|
|
55
|
+
{ name = "ezmsg", specifier = ">=3.5.0" },
|
|
56
|
+
{ name = "neo", specifier = ">=0.13.3" },
|
|
57
|
+
{ name = "pytest", marker = "extra == 'tests'", specifier = ">=8.3.3" },
|
|
58
|
+
]
|
|
59
|
+
|
|
60
|
+
[package.metadata.requires-dev]
|
|
61
|
+
dev = [{ name = "ruff", specifier = ">=0.6.8" }]
|
|
62
|
+
|
|
63
|
+
[[package]]
|
|
64
|
+
name = "iniconfig"
|
|
65
|
+
version = "2.0.0"
|
|
66
|
+
source = { registry = "https://pypi.org/simple" }
|
|
67
|
+
sdist = { url = "https://files.pythonhosted.org/packages/d7/4b/cbd8e699e64a6f16ca3a8220661b5f83792b3017d0f79807cb8708d33913/iniconfig-2.0.0.tar.gz", hash = "sha256:2d91e135bf72d31a410b17c16da610a82cb55f6b0477d1a902134b24a455b8b3", size = 4646 }
|
|
68
|
+
wheels = [
|
|
69
|
+
{ url = "https://files.pythonhosted.org/packages/ef/a6/62565a6e1cf69e10f5727360368e451d4b7f58beeac6173dc9db836a5b46/iniconfig-2.0.0-py3-none-any.whl", hash = "sha256:b6a85871a79d2e3b22d2d1b94ac2824226a63c6b741c88f7ae975f18b6778374", size = 5892 },
|
|
70
|
+
]
|
|
71
|
+
|
|
72
|
+
[[package]]
|
|
73
|
+
name = "neo"
|
|
74
|
+
version = "0.13.3"
|
|
75
|
+
source = { registry = "https://pypi.org/simple" }
|
|
76
|
+
dependencies = [
|
|
77
|
+
{ name = "numpy" },
|
|
78
|
+
{ name = "packaging" },
|
|
79
|
+
{ name = "quantities" },
|
|
80
|
+
]
|
|
81
|
+
sdist = { url = "https://files.pythonhosted.org/packages/08/4b/c863c6bff783e94c92cb814f6ae821b35e6463c5a66e809b6864d0c66b4e/neo-0.13.3.tar.gz", hash = "sha256:2d3f5900e6c887cb2e8df4181ba23531e71d7c740d6eea0c97877743313d28ae", size = 5030480 }
|
|
82
|
+
wheels = [
|
|
83
|
+
{ url = "https://files.pythonhosted.org/packages/96/78/3e62ce6bb858d308b69d8c76dd800491dccc15443fdc7e21c9b95b09e430/neo-0.13.3-py3-none-any.whl", hash = "sha256:4bbf19d6386708ca672d992c552aeffdf043c7f18b05fb34c541c07026e73489", size = 644628 },
|
|
84
|
+
]
|
|
85
|
+
|
|
86
|
+
[[package]]
|
|
87
|
+
name = "numpy"
|
|
88
|
+
version = "1.26.4"
|
|
89
|
+
source = { registry = "https://pypi.org/simple" }
|
|
90
|
+
sdist = { url = "https://files.pythonhosted.org/packages/65/6e/09db70a523a96d25e115e71cc56a6f9031e7b8cd166c1ac8438307c14058/numpy-1.26.4.tar.gz", hash = "sha256:2a02aba9ed12e4ac4eb3ea9421c420301a0c6460d9830d74a9df87efa4912010", size = 15786129 }
|
|
91
|
+
wheels = [
|
|
92
|
+
{ url = "https://files.pythonhosted.org/packages/a7/94/ace0fdea5241a27d13543ee117cbc65868e82213fb31a8eb7fe9ff23f313/numpy-1.26.4-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9ff0f4f29c51e2803569d7a51c2304de5554655a60c5d776e35b4a41413830d0", size = 20631468 },
|
|
93
|
+
{ url = "https://files.pythonhosted.org/packages/20/f7/b24208eba89f9d1b58c1668bc6c8c4fd472b20c45573cb767f59d49fb0f6/numpy-1.26.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:2e4ee3380d6de9c9ec04745830fd9e2eccb3e6cf790d39d7b98ffd19b0dd754a", size = 13966411 },
|
|
94
|
+
{ url = "https://files.pythonhosted.org/packages/fc/a5/4beee6488160798683eed5bdb7eead455892c3b4e1f78d79d8d3f3b084ac/numpy-1.26.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d209d8969599b27ad20994c8e41936ee0964e6da07478d6c35016bc386b66ad4", size = 14219016 },
|
|
95
|
+
{ url = "https://files.pythonhosted.org/packages/4b/d7/ecf66c1cd12dc28b4040b15ab4d17b773b87fa9d29ca16125de01adb36cd/numpy-1.26.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ffa75af20b44f8dba823498024771d5ac50620e6915abac414251bd971b4529f", size = 18240889 },
|
|
96
|
+
{ url = "https://files.pythonhosted.org/packages/24/03/6f229fe3187546435c4f6f89f6d26c129d4f5bed40552899fcf1f0bf9e50/numpy-1.26.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:62b8e4b1e28009ef2846b4c7852046736bab361f7aeadeb6a5b89ebec3c7055a", size = 13876746 },
|
|
97
|
+
{ url = "https://files.pythonhosted.org/packages/39/fe/39ada9b094f01f5a35486577c848fe274e374bbf8d8f472e1423a0bbd26d/numpy-1.26.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:a4abb4f9001ad2858e7ac189089c42178fcce737e4169dc61321660f1a96c7d2", size = 18078620 },
|
|
98
|
+
{ url = "https://files.pythonhosted.org/packages/d5/ef/6ad11d51197aad206a9ad2286dc1aac6a378059e06e8cf22cd08ed4f20dc/numpy-1.26.4-cp310-cp310-win32.whl", hash = "sha256:bfe25acf8b437eb2a8b2d49d443800a5f18508cd811fea3181723922a8a82b07", size = 5972659 },
|
|
99
|
+
{ url = "https://files.pythonhosted.org/packages/19/77/538f202862b9183f54108557bfda67e17603fc560c384559e769321c9d92/numpy-1.26.4-cp310-cp310-win_amd64.whl", hash = "sha256:b97fe8060236edf3662adfc2c633f56a08ae30560c56310562cb4f95500022d5", size = 15808905 },
|
|
100
|
+
{ url = "https://files.pythonhosted.org/packages/11/57/baae43d14fe163fa0e4c47f307b6b2511ab8d7d30177c491960504252053/numpy-1.26.4-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4c66707fabe114439db9068ee468c26bbdf909cac0fb58686a42a24de1760c71", size = 20630554 },
|
|
101
|
+
{ url = "https://files.pythonhosted.org/packages/1a/2e/151484f49fd03944c4a3ad9c418ed193cfd02724e138ac8a9505d056c582/numpy-1.26.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:edd8b5fe47dab091176d21bb6de568acdd906d1887a4584a15a9a96a1dca06ef", size = 13997127 },
|
|
102
|
+
{ url = "https://files.pythonhosted.org/packages/79/ae/7e5b85136806f9dadf4878bf73cf223fe5c2636818ba3ab1c585d0403164/numpy-1.26.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7ab55401287bfec946ced39700c053796e7cc0e3acbef09993a9ad2adba6ca6e", size = 14222994 },
|
|
103
|
+
{ url = "https://files.pythonhosted.org/packages/3a/d0/edc009c27b406c4f9cbc79274d6e46d634d139075492ad055e3d68445925/numpy-1.26.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:666dbfb6ec68962c033a450943ded891bed2d54e6755e35e5835d63f4f6931d5", size = 18252005 },
|
|
104
|
+
{ url = "https://files.pythonhosted.org/packages/09/bf/2b1aaf8f525f2923ff6cfcf134ae5e750e279ac65ebf386c75a0cf6da06a/numpy-1.26.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:96ff0b2ad353d8f990b63294c8986f1ec3cb19d749234014f4e7eb0112ceba5a", size = 13885297 },
|
|
105
|
+
{ url = "https://files.pythonhosted.org/packages/df/a0/4e0f14d847cfc2a633a1c8621d00724f3206cfeddeb66d35698c4e2cf3d2/numpy-1.26.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:60dedbb91afcbfdc9bc0b1f3f402804070deed7392c23eb7a7f07fa857868e8a", size = 18093567 },
|
|
106
|
+
{ url = "https://files.pythonhosted.org/packages/d2/b7/a734c733286e10a7f1a8ad1ae8c90f2d33bf604a96548e0a4a3a6739b468/numpy-1.26.4-cp311-cp311-win32.whl", hash = "sha256:1af303d6b2210eb850fcf03064d364652b7120803a0b872f5211f5234b399f20", size = 5968812 },
|
|
107
|
+
{ url = "https://files.pythonhosted.org/packages/3f/6b/5610004206cf7f8e7ad91c5a85a8c71b2f2f8051a0c0c4d5916b76d6cbb2/numpy-1.26.4-cp311-cp311-win_amd64.whl", hash = "sha256:cd25bcecc4974d09257ffcd1f098ee778f7834c3ad767fe5db785be9a4aa9cb2", size = 15811913 },
|
|
108
|
+
{ url = "https://files.pythonhosted.org/packages/95/12/8f2020a8e8b8383ac0177dc9570aad031a3beb12e38847f7129bacd96228/numpy-1.26.4-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:b3ce300f3644fb06443ee2222c2201dd3a89ea6040541412b8fa189341847218", size = 20335901 },
|
|
109
|
+
{ url = "https://files.pythonhosted.org/packages/75/5b/ca6c8bd14007e5ca171c7c03102d17b4f4e0ceb53957e8c44343a9546dcc/numpy-1.26.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:03a8c78d01d9781b28a6989f6fa1bb2c4f2d51201cf99d3dd875df6fbd96b23b", size = 13685868 },
|
|
110
|
+
{ url = "https://files.pythonhosted.org/packages/79/f8/97f10e6755e2a7d027ca783f63044d5b1bc1ae7acb12afe6a9b4286eac17/numpy-1.26.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9fad7dcb1aac3c7f0584a5a8133e3a43eeb2fe127f47e3632d43d677c66c102b", size = 13925109 },
|
|
111
|
+
{ url = "https://files.pythonhosted.org/packages/0f/50/de23fde84e45f5c4fda2488c759b69990fd4512387a8632860f3ac9cd225/numpy-1.26.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:675d61ffbfa78604709862923189bad94014bef562cc35cf61d3a07bba02a7ed", size = 17950613 },
|
|
112
|
+
{ url = "https://files.pythonhosted.org/packages/4c/0c/9c603826b6465e82591e05ca230dfc13376da512b25ccd0894709b054ed0/numpy-1.26.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:ab47dbe5cc8210f55aa58e4805fe224dac469cde56b9f731a4c098b91917159a", size = 13572172 },
|
|
113
|
+
{ url = "https://files.pythonhosted.org/packages/76/8c/2ba3902e1a0fc1c74962ea9bb33a534bb05984ad7ff9515bf8d07527cadd/numpy-1.26.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:1dda2e7b4ec9dd512f84935c5f126c8bd8b9f2fc001e9f54af255e8c5f16b0e0", size = 17786643 },
|
|
114
|
+
{ url = "https://files.pythonhosted.org/packages/28/4a/46d9e65106879492374999e76eb85f87b15328e06bd1550668f79f7b18c6/numpy-1.26.4-cp312-cp312-win32.whl", hash = "sha256:50193e430acfc1346175fcbdaa28ffec49947a06918b7b92130744e81e640110", size = 5677803 },
|
|
115
|
+
{ url = "https://files.pythonhosted.org/packages/16/2e/86f24451c2d530c88daf997cb8d6ac622c1d40d19f5a031ed68a4b73a374/numpy-1.26.4-cp312-cp312-win_amd64.whl", hash = "sha256:08beddf13648eb95f8d867350f6a018a4be2e5ad54c8d8caed89ebca558b2818", size = 15517754 },
|
|
116
|
+
{ url = "https://files.pythonhosted.org/packages/7d/24/ce71dc08f06534269f66e73c04f5709ee024a1afe92a7b6e1d73f158e1f8/numpy-1.26.4-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:7349ab0fa0c429c82442a27a9673fc802ffdb7c7775fad780226cb234965e53c", size = 20636301 },
|
|
117
|
+
{ url = "https://files.pythonhosted.org/packages/ae/8c/ab03a7c25741f9ebc92684a20125fbc9fc1b8e1e700beb9197d750fdff88/numpy-1.26.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:52b8b60467cd7dd1e9ed082188b4e6bb35aa5cdd01777621a1658910745b90be", size = 13971216 },
|
|
118
|
+
{ url = "https://files.pythonhosted.org/packages/6d/64/c3bcdf822269421d85fe0d64ba972003f9bb4aa9a419da64b86856c9961f/numpy-1.26.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d5241e0a80d808d70546c697135da2c613f30e28251ff8307eb72ba696945764", size = 14226281 },
|
|
119
|
+
{ url = "https://files.pythonhosted.org/packages/54/30/c2a907b9443cf42b90c17ad10c1e8fa801975f01cb9764f3f8eb8aea638b/numpy-1.26.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f870204a840a60da0b12273ef34f7051e98c3b5961b61b0c2c1be6dfd64fbcd3", size = 18249516 },
|
|
120
|
+
{ url = "https://files.pythonhosted.org/packages/43/12/01a563fc44c07095996d0129b8899daf89e4742146f7044cdbdb3101c57f/numpy-1.26.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:679b0076f67ecc0138fd2ede3a8fd196dddc2ad3254069bcb9faf9a79b1cebcd", size = 13882132 },
|
|
121
|
+
{ url = "https://files.pythonhosted.org/packages/16/ee/9df80b06680aaa23fc6c31211387e0db349e0e36d6a63ba3bd78c5acdf11/numpy-1.26.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:47711010ad8555514b434df65f7d7b076bb8261df1ca9bb78f53d3b2db02e95c", size = 18084181 },
|
|
122
|
+
{ url = "https://files.pythonhosted.org/packages/28/7d/4b92e2fe20b214ffca36107f1a3e75ef4c488430e64de2d9af5db3a4637d/numpy-1.26.4-cp39-cp39-win32.whl", hash = "sha256:a354325ee03388678242a4d7ebcd08b5c727033fcff3b2f536aea978e15ee9e6", size = 5976360 },
|
|
123
|
+
{ url = "https://files.pythonhosted.org/packages/b5/42/054082bd8220bbf6f297f982f0a8f5479fcbc55c8b511d928df07b965869/numpy-1.26.4-cp39-cp39-win_amd64.whl", hash = "sha256:3373d5d70a5fe74a2c1bb6d2cfd9609ecf686d47a2d7b1d37a8f3b6bf6003aea", size = 15814633 },
|
|
124
|
+
{ url = "https://files.pythonhosted.org/packages/3f/72/3df6c1c06fc83d9cfe381cccb4be2532bbd38bf93fbc9fad087b6687f1c0/numpy-1.26.4-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:afedb719a9dcfc7eaf2287b839d8198e06dcd4cb5d276a3df279231138e83d30", size = 20455961 },
|
|
125
|
+
{ url = "https://files.pythonhosted.org/packages/8e/02/570545bac308b58ffb21adda0f4e220ba716fb658a63c151daecc3293350/numpy-1.26.4-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:95a7476c59002f2f6c590b9b7b998306fba6a5aa646b1e22ddfeaf8f78c3a29c", size = 18061071 },
|
|
126
|
+
{ url = "https://files.pythonhosted.org/packages/f4/5f/fafd8c51235f60d49f7a88e2275e13971e90555b67da52dd6416caec32fe/numpy-1.26.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:7e50d0a0cc3189f9cb0aeb3a6a6af18c16f59f004b866cd2be1c14b36134a4a0", size = 15709730 },
|
|
127
|
+
]
|
|
128
|
+
|
|
129
|
+
[[package]]
|
|
130
|
+
name = "packaging"
|
|
131
|
+
version = "24.1"
|
|
132
|
+
source = { registry = "https://pypi.org/simple" }
|
|
133
|
+
sdist = { url = "https://files.pythonhosted.org/packages/51/65/50db4dda066951078f0a96cf12f4b9ada6e4b811516bf0262c0f4f7064d4/packaging-24.1.tar.gz", hash = "sha256:026ed72c8ed3fcce5bf8950572258698927fd1dbda10a5e981cdf0ac37f4f002", size = 148788 }
|
|
134
|
+
wheels = [
|
|
135
|
+
{ url = "https://files.pythonhosted.org/packages/08/aa/cc0199a5f0ad350994d660967a8efb233fe0416e4639146c089643407ce6/packaging-24.1-py3-none-any.whl", hash = "sha256:5b8f2217dbdbd2f7f384c41c628544e6d52f2d0f53c6d0c3ea61aa5d1d7ff124", size = 53985 },
|
|
136
|
+
]
|
|
137
|
+
|
|
138
|
+
[[package]]
|
|
139
|
+
name = "pluggy"
|
|
140
|
+
version = "1.5.0"
|
|
141
|
+
source = { registry = "https://pypi.org/simple" }
|
|
142
|
+
sdist = { url = "https://files.pythonhosted.org/packages/96/2d/02d4312c973c6050a18b314a5ad0b3210edb65a906f868e31c111dede4a6/pluggy-1.5.0.tar.gz", hash = "sha256:2cffa88e94fdc978c4c574f15f9e59b7f4201d439195c3715ca9e2486f1d0cf1", size = 67955 }
|
|
143
|
+
wheels = [
|
|
144
|
+
{ url = "https://files.pythonhosted.org/packages/88/5f/e351af9a41f866ac3f1fac4ca0613908d9a41741cfcf2228f4ad853b697d/pluggy-1.5.0-py3-none-any.whl", hash = "sha256:44e1ad92c8ca002de6377e165f3e0f1be63266ab4d554740532335b9d75ea669", size = 20556 },
|
|
145
|
+
]
|
|
146
|
+
|
|
147
|
+
[[package]]
|
|
148
|
+
name = "pytest"
|
|
149
|
+
version = "8.3.3"
|
|
150
|
+
source = { registry = "https://pypi.org/simple" }
|
|
151
|
+
dependencies = [
|
|
152
|
+
{ name = "colorama", marker = "sys_platform == 'win32'" },
|
|
153
|
+
{ name = "exceptiongroup", marker = "python_full_version < '3.11'" },
|
|
154
|
+
{ name = "iniconfig" },
|
|
155
|
+
{ name = "packaging" },
|
|
156
|
+
{ name = "pluggy" },
|
|
157
|
+
{ name = "tomli", marker = "python_full_version < '3.11'" },
|
|
158
|
+
]
|
|
159
|
+
sdist = { url = "https://files.pythonhosted.org/packages/8b/6c/62bbd536103af674e227c41a8f3dcd022d591f6eed5facb5a0f31ee33bbc/pytest-8.3.3.tar.gz", hash = "sha256:70b98107bd648308a7952b06e6ca9a50bc660be218d53c257cc1fc94fda10181", size = 1442487 }
|
|
160
|
+
wheels = [
|
|
161
|
+
{ url = "https://files.pythonhosted.org/packages/6b/77/7440a06a8ead44c7757a64362dd22df5760f9b12dc5f11b6188cd2fc27a0/pytest-8.3.3-py3-none-any.whl", hash = "sha256:a6853c7375b2663155079443d2e45de913a911a11d669df02a50814944db57b2", size = 342341 },
|
|
162
|
+
]
|
|
163
|
+
|
|
164
|
+
[[package]]
|
|
165
|
+
name = "quantities"
|
|
166
|
+
version = "0.15.0"
|
|
167
|
+
source = { registry = "https://pypi.org/simple" }
|
|
168
|
+
dependencies = [
|
|
169
|
+
{ name = "numpy" },
|
|
170
|
+
]
|
|
171
|
+
sdist = { url = "https://files.pythonhosted.org/packages/06/1a/d7288e6293d6ca10b0dd7a94a9ee9462cd2f2031ee52e135ff7efc04cfef/quantities-0.15.0.tar.gz", hash = "sha256:9ea31e2a0d7517cf24d546b14146def9292639993a616cca61b875ef796b4b2b", size = 99702 }
|
|
172
|
+
wheels = [
|
|
173
|
+
{ url = "https://files.pythonhosted.org/packages/3a/aa/2d37dc5a180585b8b10aac671529625b72c8a6908b6b8b8bf0b1f8e35101/quantities-0.15.0-py3-none-any.whl", hash = "sha256:589bdadcbbdc1c10950120c6d197f7e71ac145512a4b4ac5fd40d4946709d6ec", size = 101218 },
|
|
174
|
+
]
|
|
175
|
+
|
|
176
|
+
[[package]]
|
|
177
|
+
name = "ruff"
|
|
178
|
+
version = "0.6.8"
|
|
179
|
+
source = { registry = "https://pypi.org/simple" }
|
|
180
|
+
sdist = { url = "https://files.pythonhosted.org/packages/74/f9/4ce3e765a72ab8fe0f80f48508ea38b4196daab3da14d803c21349b2d367/ruff-0.6.8.tar.gz", hash = "sha256:a5bf44b1aa0adaf6d9d20f86162b34f7c593bfedabc51239953e446aefc8ce18", size = 3084543 }
|
|
181
|
+
wheels = [
|
|
182
|
+
{ url = "https://files.pythonhosted.org/packages/db/07/42ee57e8b76ca585297a663a552b4f6d6a99372ca47fdc2276ef72cc0f2f/ruff-0.6.8-py3-none-linux_armv6l.whl", hash = "sha256:77944bca110ff0a43b768f05a529fecd0706aac7bcce36d7f1eeb4cbfca5f0f2", size = 10404327 },
|
|
183
|
+
{ url = "https://files.pythonhosted.org/packages/eb/51/d42571ff8156d65086acb72d39aa64cb24181db53b497d0ed6293f43f07a/ruff-0.6.8-py3-none-macosx_10_12_x86_64.whl", hash = "sha256:27b87e1801e786cd6ede4ada3faa5e254ce774de835e6723fd94551464c56b8c", size = 10018797 },
|
|
184
|
+
{ url = "https://files.pythonhosted.org/packages/c1/d7/fa5514a60b03976af972b67fe345deb0335dc96b9f9a9fa4df9890472427/ruff-0.6.8-py3-none-macosx_11_0_arm64.whl", hash = "sha256:cd48f945da2a6334f1793d7f701725a76ba93bf3d73c36f6b21fb04d5338dcf5", size = 9691303 },
|
|
185
|
+
{ url = "https://files.pythonhosted.org/packages/d6/c4/d812a74976927e51d0782a47539069657ac78535779bfa4d061c4fc8d89d/ruff-0.6.8-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:677e03c00f37c66cea033274295a983c7c546edea5043d0c798833adf4cf4c6f", size = 10719452 },
|
|
186
|
+
{ url = "https://files.pythonhosted.org/packages/ec/b6/aa700c4ae6db9b3ee660e23f3c7db596e2b16a3034b797704fba33ddbc96/ruff-0.6.8-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:9f1476236b3eacfacfc0f66aa9e6cd39f2a624cb73ea99189556015f27c0bdeb", size = 10161353 },
|
|
187
|
+
{ url = "https://files.pythonhosted.org/packages/ea/39/0b10075ffcd52ff3a581b9b69eac53579deb230aad300ce8f9d0b58e77bc/ruff-0.6.8-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6f5a2f17c7d32991169195d52a04c95b256378bbf0de8cb98478351eb70d526f", size = 10980630 },
|
|
188
|
+
{ url = "https://files.pythonhosted.org/packages/c1/af/9eb9efc98334f62652e2f9318f137b2667187851911fac3b395365a83708/ruff-0.6.8-py3-none-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:5fd0d4b7b1457c49e435ee1e437900ced9b35cb8dc5178921dfb7d98d65a08d0", size = 11768996 },
|
|
189
|
+
{ url = "https://files.pythonhosted.org/packages/e0/59/8b1369cf7878358952b1c0a1559b4d6b5c824c003d09b0db26d26c9d094f/ruff-0.6.8-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:f8034b19b993e9601f2ddf2c517451e17a6ab5cdb1c13fdff50c1442a7171d87", size = 11317469 },
|
|
190
|
+
{ url = "https://files.pythonhosted.org/packages/b9/6d/e252e9b11bbca4114c386ee41ad559d0dac13246201d77ea1223c6fea17f/ruff-0.6.8-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:6cfb227b932ba8ef6e56c9f875d987973cd5e35bc5d05f5abf045af78ad8e098", size = 12467185 },
|
|
191
|
+
{ url = "https://files.pythonhosted.org/packages/48/44/7caa223af7d4ea0f0b2bd34acca65a7694a58317714675a2478815ab3f45/ruff-0.6.8-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6ef0411eccfc3909269fed47c61ffebdcb84a04504bafa6b6df9b85c27e813b0", size = 10887766 },
|
|
192
|
+
{ url = "https://files.pythonhosted.org/packages/81/ed/394aff3a785f171869158b9d5be61eec9ffb823c3ad5d2bdf2e5f13cb029/ruff-0.6.8-py3-none-musllinux_1_2_aarch64.whl", hash = "sha256:007dee844738c3d2e6c24ab5bc7d43c99ba3e1943bd2d95d598582e9c1b27750", size = 10711609 },
|
|
193
|
+
{ url = "https://files.pythonhosted.org/packages/47/31/f31d04c842e54699eab7e3b864538fea26e6c94b71806cd10aa49f13e1c1/ruff-0.6.8-py3-none-musllinux_1_2_armv7l.whl", hash = "sha256:ce60058d3cdd8490e5e5471ef086b3f1e90ab872b548814e35930e21d848c9ce", size = 10237621 },
|
|
194
|
+
{ url = "https://files.pythonhosted.org/packages/20/95/a764e84acf11d425f2f23b8b78b4fd715e9c20be4aac157c6414ca859a67/ruff-0.6.8-py3-none-musllinux_1_2_i686.whl", hash = "sha256:1085c455d1b3fdb8021ad534379c60353b81ba079712bce7a900e834859182fa", size = 10558329 },
|
|
195
|
+
{ url = "https://files.pythonhosted.org/packages/2a/76/d4e38846ac9f6dd62dce858a54583911361b5339dcf8f84419241efac93a/ruff-0.6.8-py3-none-musllinux_1_2_x86_64.whl", hash = "sha256:70edf6a93b19481affd287d696d9e311388d808671bc209fb8907b46a8c3af44", size = 10954102 },
|
|
196
|
+
{ url = "https://files.pythonhosted.org/packages/e7/36/f18c678da6c69f8d022480f3e8ddce6e4a52e07602c1d212056fbd234f8f/ruff-0.6.8-py3-none-win32.whl", hash = "sha256:792213f7be25316f9b46b854df80a77e0da87ec66691e8f012f887b4a671ab5a", size = 8511090 },
|
|
197
|
+
{ url = "https://files.pythonhosted.org/packages/4c/c4/0ca7d8ffa358b109db7d7d045a1a076fd8e5d9cbeae022242d3c060931da/ruff-0.6.8-py3-none-win_amd64.whl", hash = "sha256:ec0517dc0f37cad14a5319ba7bba6e7e339d03fbf967a6d69b0907d61be7a263", size = 9350079 },
|
|
198
|
+
{ url = "https://files.pythonhosted.org/packages/d9/bd/a8b0c64945a92eaeeb8d0283f27a726a776a1c9d12734d990c5fc7a1278c/ruff-0.6.8-py3-none-win_arm64.whl", hash = "sha256:8d3bb2e3fbb9875172119021a13eed38849e762499e3cfde9588e4b4d70968dc", size = 8669595 },
|
|
199
|
+
]
|
|
200
|
+
|
|
201
|
+
[[package]]
|
|
202
|
+
name = "tomli"
|
|
203
|
+
version = "2.0.1"
|
|
204
|
+
source = { registry = "https://pypi.org/simple" }
|
|
205
|
+
sdist = { url = "https://files.pythonhosted.org/packages/c0/3f/d7af728f075fb08564c5949a9c95e44352e23dee646869fa104a3b2060a3/tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f", size = 15164 }
|
|
206
|
+
wheels = [
|
|
207
|
+
{ url = "https://files.pythonhosted.org/packages/97/75/10a9ebee3fd790d20926a90a2547f0bf78f371b2f13aa822c759680ca7b9/tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc", size = 12757 },
|
|
208
|
+
]
|
|
209
|
+
|
|
210
|
+
[[package]]
|
|
211
|
+
name = "typing-extensions"
|
|
212
|
+
version = "4.12.2"
|
|
213
|
+
source = { registry = "https://pypi.org/simple" }
|
|
214
|
+
sdist = { url = "https://files.pythonhosted.org/packages/df/db/f35a00659bc03fec321ba8bce9420de607a1d37f8342eee1863174c69557/typing_extensions-4.12.2.tar.gz", hash = "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8", size = 85321 }
|
|
215
|
+
wheels = [
|
|
216
|
+
{ url = "https://files.pythonhosted.org/packages/26/9f/ad63fc0248c5379346306f8668cda6e2e2e9c95e01216d2b8ffd9ff037d0/typing_extensions-4.12.2-py3-none-any.whl", hash = "sha256:04e5ca0351e0f3f85c6853954072df659d0d13fac324d0072316b67d7794700d", size = 37438 },
|
|
217
|
+
]
|