MeaPy
Python API Wrapper for Measurement Data
Vision
MeaPy wants to be a easy-to-use and conformable API for working with measurement data in den Big Test Data environment.
Getting Started
pip install meapy
Usage
To create a meapy session, you need to connect to the MaDaM system.n
from meapy import MeaPy, MeasurementList, LoadingConfig
# "Basic " is the content if the HTTP Authorization-Header. In this example it is the Basic Authentication Header for user:password
mp = MeaPy("http://madam-docker.int.kistler.com:8081/", "Basic dXNlcjpwYXNzd29yZA==")
Search
# direct search (by default limited to 100 results)
result = mp.search("test")
# result is a list of meapy.Measurement
# search and iteration over the whole result set
ml = MeasurementList(mp)
count = 0
for mea in ml.items('Station.Id="d4f1ad55-72d5-403c-81b8-73b2942b58f4"'):
count+=1
print(count)
Loading Signals
The measurements that were returned from the search can be used to load the signals directly from the MaDaM system.
result = mp.search("test", limit = 1)
measurement = result[0]
# load a measurement
config = LoadingConfig()
config.withSignals(['time'])
signals = mp.load(measurement, config)
# signals is a list of meapy.SignalData that contains the information for the requested channels
Update Measurement Metadata
result = mp.search("test", limit = 1)
measurement = result[0]
# update the metadata with some additional data
data = {'someField': 'someValue'}
mp.update(measurement, data)
Upload a new Measurement
# upload a pandas DataFrame to MaDaM with a given name.
df = pd.DataFrame(np.random.randint(0, 100, size=(100, 4)), columns=list('ABCD'))
# you can also add some additional metadata here
data = {'someField': 'someValue'}
mp.upload("random-data", df, data)
# after successful upload, you can find the new measurement "random-data.csv"
Metadata
Release files for meapy 0.0.13
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| meapy-0.0.13.tar.gz | 8.4 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| meapy-0.0.13-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 16.6 kB
Release files / meapy-0.0.13.tar.gz
| Download URL | meapy-0.0.13.tar.gz |
|---|---|
| Size | 8.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4c9f4192f2c0c2da9b6c86a7b33dc29b17f2eb25805c7756e3acee232abef524
|
|
BLAKE2b-256 checksum How to use checksums |
bb1805f512823ce9eb36a83e98eb36caac1c32bffa3a5d28b4c9a6a735adebb3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.5
|
Release files / meapy-0.0.13-py3-none-any.whl
| Download URL | meapy-0.0.13-py3-none-any.whl |
|---|---|
| Size | 8.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
bdde27e0da6dce6cd6548048d69b28950b25d063493b66eb0001dfb80fb41726
|
|
BLAKE2b-256 checksum How to use checksums |
1ffa2ea0d59dc5b79cb4b8919060ab3067a0efd131302647f4d052edb77082b3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.5
|
Security for meapy 0.0.13
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.