Collect raw timeseries data from 24SEA influxdb, compliant with SDyPy SEP005
Project description
SEP005 24SEA io influxdb
Basic package to import data collected from the 24SEA DF2.0 influx-db compliant with SDyPy format for timeseries as proposed in SEP005.
Installation
Important prerequisite
As written in the documentation of the python influx-db client, it is recommended to use ciso8601 with client for parsing dates. ciso8601 is much faster than built-in Python datetime. Since it’s written as a C module the best way is build it from sources:
Easiest way to install is through conda : conda install -c conda-forge/label/cf202003 ciso8601
Client configuration
The influxdb client is best configured using the a configuration file. For 24SEA application this can be done using the project’s {project_name}_postprocessing.ini configuration file.
[influx2]
url=http://influx01.24sea.local:8086/
org=24sea
token=my-token
verify_ssl=False
bucket=metrics
Using the package
The key Class is Influx24SEAreader and its ‘.get()’ statement.
import datetime from pytz import utc from sep005_io_24sea_influxdb import Influx24SEAreader ini_files = # Add path to {project_name}_postprocessing.ini file client = Influx24SEAreader().from_config_file(config_file=ini_file) dt = datetime.datetime(2024,11,15,14,tzinfo=utc) location = 'WTG001' with client: client.get( start=dt, location='WTG01', # Location_id as in influxdb database sensor_type='ACC', # type as specified in the influxdb )
Once collected the data is stored inside the client object. E.g. accessible through client.df. However, it can be directly be exported to sep005 using : client.to_sep005()
Acknowledgements
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sep005_io_24sea_influxdb-0.0.2.tar.gz.
File metadata
- Download URL: sep005_io_24sea_influxdb-0.0.2.tar.gz
- Upload date:
- Size: 5.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
853c2122b501f6b5977de6f82bc9aeced2d17cc853b820998231078cd967c116
|
|
| MD5 |
47c0119ae311aa31a1896c4970705991
|
|
| BLAKE2b-256 |
3ea903a5d7635caf14c4d564c4d20e14a7a0bd2a69a43251899b73f560618d50
|
File details
Details for the file sep005_io_24sea_influxdb-0.0.2-py3-none-any.whl.
File metadata
- Download URL: sep005_io_24sea_influxdb-0.0.2-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.9.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
068559ae31c69a30446348a3c1e4ad152336b3c1e662f61c2032f49a30945906
|
|
| MD5 |
1b9f032f865571e19cd036cc1e1d3ebc
|
|
| BLAKE2b-256 |
be75e1601b4bf4d4f7d802b51fb1b11ac2304b30363da5ae0b7f741df401a771
|