-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #63 from KCL-BMEIS/62-raw-waveforms-in-conveninece…
…-methods #62 raw waveforms in convenience methods
- Loading branch information
Showing
11 changed files
with
45 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,19 @@ | ||
from datetime import datetime | ||
from dataclasses import dataclass | ||
from typing import List, Optional | ||
|
||
from numpy import float_ | ||
from numpy import int16, float64 | ||
from numpy.typing import NDArray | ||
|
||
|
||
VoltageWaveformType = NDArray[float64] | ||
RawWaveformType = NDArray[int16] | ||
|
||
|
||
@dataclass | ||
class Measurement: | ||
"""Measurement is a dataclass for storing a set of waveforms generated by a single acquisition, with a timestamp.""" | ||
|
||
waveforms: List[NDArray[float_]] | ||
"""Contains the acquired waveforms as a list of 1D NumPy arrays""" | ||
timestamp: Optional[datetime] | ||
waveforms: list[VoltageWaveformType] | list[RawWaveformType] | ||
"""Contains the acquired waveforms as a list of 1D NumPy arrays or either floats or ints""" | ||
timestamp: datetime | None | ||
"""The time at which the acquisition was triggered, as a datetime.datetime object""" |