Metadata-Version: 2.1
Name: h5-info-pkg-inra-phenome
Version: 1.0.2
Summary: Utility package for extracting, reading and saving metadata from HDF5 Phenomobile V2 acquisition file
Home-page: https://forgemia.inra.fr/4p/tools/h5info
Author: Eric David
Author-email: eric.david@ephesia-consult.com
License: UNKNOWN
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.8
Description-Content-Type: text/markdown

# H5Info Package

This Python package contains the necessary tools to extract data and metadata from HDF5 files generated by Phenomobile acquisition in the context of the Phenome project by INRA, France.

The API of the H5Info package exposes 3 methods:

- ``load_data()``: to extract data from a HDF5 file and store it into a H5Info structure
- ``save_metadata()``: to save a H5Info metadata structure into a JSON  file
- ``load_metadata()``: to load a H5Info metadata structure from a JSON file

Please refer to the ``main.py`` script for an example about how to use these three methods.

## H5Info Structure Example

``h5_info = H5Info()``

### Session

- ``h5_info.session.date = "2020-02-03_09:45:23"``
- ``h5_info.session.experiment_id = "2019_SunRise"``
- ``h5_info.session.experiment_uri = "http://www.phenome-fppn.fr/diaphen/2019/v1901"``
- ``h5_info.session.local_infra = "Diaphen"``
- ``h5_info.session.national_infra = "PHENOME"``

### Plot

- ``h5_info.plot.id = "20LP4_129_8_1039"``
- ``h5_info.plot.uri = "http://www.phenome-fppn.fr/diaphen/2018/v1801"``
- ``h5_info.plot.coordinates = [[1.5015271931087, 43.532682695713], [1.5015062032854, 43.532676540606], [1.5014877113578, 43.532709920144], [1.5015087011914, 43.532716075254]]``
- ``h5_info.plot.orientation = 158.04785481961858``

### Vector

- ``h5_info.vector.id = "Phenomobile V2"``
- ``h5_info.vector.uri = "http://www.phenome-fppn.fr/diaphen/2018/v1801"``
- ``h5_info.vector.serial_nb = "PHENOMOBILE_V2_01"``

### Sensors

``for sensor in h5_info.sensors:``

- ``sensor.id = "4"``
- ``sensor.type = "camera"``
- ``sensor.description = "camera_1"``
- ``sensor.manufacturer = "Baumer"``
- ``sensor.model = "VLG 40C"``
- ``sensor.serial_nb = "00_06_be_01_62_f0"``
- ``sensor.uri = "http://www.phenome-fppn.fr/agrophen/2019/s19003"``

### Others fields

The H5Info structure contains other fields not detailed here, such as the ``vector position``, each ``sensor positions`` and ``static transforms`` factors.

