-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
7 changed files
with
140 additions
and
274 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
.. _Template api: | ||
|
||
============ | ||
Template | ||
============ | ||
|
||
The template class holds the information on how to interpret raw datafiles. | ||
This is done by mapping to standards defined in the toolkit. See the :ref:`Mapping to the toolkit`_ section. | ||
|
||
|
||
.. note:: | ||
In practice, a user does not need to interact with the `Template()` class. A | ||
`Template()` instance is constructed from a templatefile (json). The user | ||
must create this templatefile, and the `Template()` is constructed from it. | ||
|
||
The `Template` is stored as an attribute of a `Dataset`, and it can be reached as such. | ||
|
||
|
||
.. code-block:: python | ||
import metobs_toolkit | ||
your_dataset = metobs_toolkit.Dataset() | ||
your_dataset.update_settings( | ||
input_data_file=" ... ", | ||
input_metadata_file=" ... ", | ||
template_file=" ... ", # path to your template file (json) | ||
) | ||
# Importing the data will construct the Template | ||
your_dataset.import_data_from_file() | ||
# The Template is stored in each Dataset | ||
your_dataset.template | ||
.. currentmodule:: metobs_toolkit | ||
|
||
Constructing a templatefile | ||
----------------------------- | ||
|
||
.. autosummary:: | ||
:toctree: api/ | ||
|
||
build_template_prompt | ||
|
||
|
||
|
||
Common methods | ||
-------------------- | ||
|
||
.. autosummary:: | ||
:toctree: api/ | ||
|
||
template.Template.get_info | ||
template.Template.show |
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
Oops, something went wrong.