Skip to content

Commit 1ab65c4

Browse files
committed
Enhanced docs
1 parent a8fd5b9 commit 1ab65c4

File tree

3 files changed

+28
-6
lines changed

3 files changed

+28
-6
lines changed

docs/api.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,10 @@ All described objects can be imported from the `zappend.api` module.
4646
options:
4747
show_root_heading: true
4848

49-
## Function `write_levels()` for `xcube`
49+
## Contributions
5050

51-
::: zappend.levels.write_levels
52-
options:
53-
show_root_heading: true
51+
::: zappend.contrib
52+
53+
### Function `write_levels()`
54+
55+
::: zappend.contrib.write_levels

zappend/contrib/__init__.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,14 @@
22
# Permissions are hereby granted under the terms of the MIT License:
33
# https://opensource.org/licenses/MIT.
44

5+
"""
6+
This module contributes to zappend's core functionality.
7+
8+
The function signatures in this module are less stable, and their implementations
9+
are considered experimental. They may also rely on external packages. For more
10+
information, please refer to the individual function documentation.
11+
Due to these reasons, this module is excluded from the project's automatic
12+
coverage analysis.
13+
"""
14+
515
from .levels import write_levels

zappend/contrib/levels.py

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def write_levels(
3131
xy_dim_names: tuple[str, str] | None = None,
3232
**zappend_config,
3333
):
34-
"""Writes a dataset given by `source_ds` or `source_path` to `target_path`
34+
"""Write a dataset given by `source_ds` or `source_path` to `target_path`
3535
using the
3636
[multi-level dataset format](https://xcube.readthedocs.io/en/latest/mldatasets.html)
3737
as specified by
@@ -59,7 +59,17 @@ def write_levels(
5959
If configuration parameter `variables` is also given as part of
6060
`zappend_config`, it will be merged with the chunk definitions.
6161
62-
Important: This function requires the `xcube` package to be installed.
62+
**Important notes:**
63+
64+
- This function requires the `xcube` package.
65+
- `write_levels()` is not as robust as zappend itself. For example,
66+
there may be inconsistent dataset levels if the processing
67+
is interrupted while a level is appended.
68+
- There is a remaining issue that with (coordinate) variables that
69+
have a dimension that is not a dimension of any variable that has
70+
one of the spatial dimensions, e.g., `time_bnds` with dimensions
71+
`time` and `bnds`. Please exclude such variables using the parameter
72+
`excluded_variables`.
6373
6474
Args:
6575
source_ds: The source dataset.

0 commit comments

Comments
 (0)