Skip to content
Snippets Groups Projects
Commit 72a3eaed authored by BastianTigges's avatar BastianTigges
Browse files

Merge branch 'main' of git.rwth-aachen.de:fst-tuda/projects/rdm/adp-pykraken/pykkn

parents c99cf4af f3020f8a
No related branches found
No related tags found
No related merge requests found
......@@ -2,7 +2,7 @@ from pykkn.build_multi_parameters import build_multi_parameters
dic = {
"list_of_parameters": [
{"name": "name_of_parameter_1", "value": 123},
{"name": "fan/diameter", "value": 1235, "units": 'm'},
{"name": "name_of_parameter_2", "value": 456},
{"name": "name_of_parameter_3", "value": 789},
]
......@@ -12,4 +12,4 @@ list_parameters = build_multi_parameters(dic)
print(list_parameters)
for parameter in list_parameters:
print(parameter)
parameter.show()
......@@ -48,5 +48,11 @@ msmtrun.set_storage_path("example_for_docs.h5")
msmtrun.store()
result_msmtrun = pykkn_parse("example_for_docs.h5")
result_msmtrun.show()
\ No newline at end of file
......@@ -13,20 +13,18 @@ class Pipeline(Storage):
This name of pipeline should contain the following information: \n
<measured/derived>/<capa>/<raw/scaled>
Parameters
----------
name : str
the name of the pipeline
Examples
--------
pipeline1 = Pipeline('measured/capa1/raw') \n
pipeline1.attrs['variable'] = 'voltage' \n
pipeline1.attrs['units'] = 'volts' \n
pipeline1.attrs['origin'] = 'this' \n
pipeline.add([dataset1, dataset2]) \n
pipeline.add([instrument1, insturment2]) \n
Args:
name (str): the name of the pipeline
Example:
pipeline1 = Pipeline('measured/capa1/raw') \n
pipeline1.attrs['variable'] = 'voltage' \n
pipeline1.attrs['units'] = 'volts' \n
pipeline1.attrs['origin'] = 'this' \n
pipeline.add([dataset1, dataset2]) \n
pipeline.add([instrument1, insturment2]) \n
"""
def __init__(self, name: str):
......@@ -46,17 +44,15 @@ class Pipeline(Storage):
def add(self, list_obj: List[Instrument | Dataset]):
"""add (multi) dataset(s) and instrument(s) into model
Parameters
----------
list_obj : List[Instrument | Dataset]
a list of Instrument or Dataset object(s)
Raises
------
TypeError
raised when the element is not the type of Instrument or Dataset
AssertionError
raised when list_obj is not a list or it is empty
Args:
list_obj (List[Instrument | Dataset]):
a list of Instrument or Dataset object(s)
Raises:
TypeError: raised when the element is not the type of Instrument
or Dataset
AssertionError: raised when list_obj is not a list or it is empty
"""
# Before extend the list of attributes
......
import components
\ No newline at end of file
from pykkn.parse import pykkn_parse
object = pykkn_parse('C:/Users/Administrator/Desktop/HDF5_From_Martin.h5')
object.show()
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment