You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/config.md
+75-60Lines changed: 75 additions & 60 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,15 +1,31 @@
1
1
# Configuration Reference
2
2
3
-
Given here are all configuration settings of `zappend`.
4
3
5
-
## Target Outline
4
+
## `version`
6
5
7
-
### `append_dim`
6
+
Configuration schema version. Allows the schema to evolve while still preserving backwards compatibility.
7
+
Its value is `1`.
8
+
Defaults to `1`.
9
+
10
+
## `zarr_version`
11
+
12
+
The Zarr version to be used.
13
+
Its value is `2`.
14
+
Defaults to `2`.
15
+
16
+
## `fixed_dims`
17
+
18
+
Type _object_.
19
+
Specifies the fixed dimensions of the target dataset. Keys are dimension names, values are dimension sizes.
20
+
The object's values are of type _integer_.
21
+
22
+
## `append_dim`
8
23
9
24
Type _string_.
10
25
The name of the variadic append dimension.
11
26
Defaults to `"time"`.
12
-
### `append_step`
27
+
28
+
## `append_step`
13
29
14
30
If set, enforces a step size in the append dimension between two slices or just enforces a direction.
15
31
Must be one of the following:
@@ -30,22 +46,20 @@ Must be one of the following:
30
46
A positive or negative numerical delta value.
31
47
32
48
Defaults to `null`.
33
-
### `fixed_dims`
34
49
35
-
Type _object_.
36
-
Specifies the fixed dimensions of the target dataset. Keys are dimension names, values are dimension sizes.
37
-
The object's values are of type _integer_.
38
-
### `included_variables`
50
+
## `included_variables`
39
51
40
52
Type _array_.
41
53
Specifies the names of variables to be included in the target dataset. Defaults to all variables found in the first contributing dataset.
42
54
The items of the array are of type _string_.
43
-
### `excluded_variables`
55
+
56
+
## `excluded_variables`
44
57
45
58
Type _array_.
46
59
Specifies the names of individual variables to be excluded from all contributing datasets.
47
60
The items of the array are of type _string_.
48
-
### `variables`
61
+
62
+
## `variables`
49
63
50
64
Type _object_.
51
65
Defines dimensions, encoding, and attributes for variables in the target dataset. Object property names refer to variable names. The special name `*` refers to all variables, which is useful for defining common values.
@@ -135,11 +149,13 @@ Variable metadata.
135
149
*`attrs`:
136
150
Type _object_.
137
151
Arbitrary variable metadata attributes.
138
-
### `attrs`
152
+
153
+
## `attrs`
139
154
140
155
Type _object_.
141
156
Arbitrary dataset attributes. If `permit_eval` is set to `true`, string values may include Python expressions enclosed in `{{` and `}}` to dynamically compute attribute values; in the expression, the current dataset is named `ds`. Refer to the user guide for more information.
142
-
### `attrs_update_mode`
157
+
158
+
## `attrs_update_mode`
143
159
144
160
The mode used update target attributes from slice attributes. Independently of this setting, extra attributes configured by the `attrs` setting will finally be used to update the resulting target attributes.
145
161
Must be one of the following:
@@ -157,37 +173,44 @@ Must be one of the following:
157
173
Its value is `"ignore"`.
158
174
159
175
Defaults to `"keep"`.
160
-
### `zarr_version`
161
176
162
-
The Zarr version to be used.
163
-
Its value is `2`.
164
-
Defaults to `2`.
165
-
## Data I/O - Target
177
+
## `permit_eval`
178
+
179
+
Type _boolean_.
180
+
Allow for dynamically computed values in dataset attributes `attrs` using the syntax `{{ expression }}`. Executing arbitrary Python expressions is a security risk, therefore this must be explicitly enabled. Refer to the user guide for more information.
181
+
Defaults to `false`.
166
182
167
-
###`target_dir`
183
+
## `target_dir`
168
184
169
185
Type _string_.
170
186
The URI or local path of the target Zarr dataset. Must specify a directory whose parent directory must exist.
171
-
### `target_storage_options`
187
+
188
+
## `target_storage_options`
172
189
173
190
Type _object_.
174
191
Options for the filesystem given by the URI of `target_dir`.
175
-
### `force_new`
176
192
177
-
Type _boolean_.
178
-
Force creation of a new target dataset. An existing target dataset (and its lock) will be permanently deleted before appending of slice datasets begins. WARNING: the deletion cannot be rolled back.
179
-
Defaults to `false`.
180
-
## Data I/O - Slices
193
+
## `slice_source`
181
194
182
-
### `slice_storage_options`
195
+
Type _string_.
196
+
The fully qualified name of a class or function that receives a slice item as argument(s) and provides the slice dataset. If a class is given, it must be derived from `zappend.api.SliceSource`. If the function is a context manager, it must yield an `xarray.Dataset`. If a plain function is given, it must return any valid slice item type. Refer to the user guide for more information.
197
+
198
+
## `slice_source_kwargs`
183
199
184
200
Type _object_.
185
-
Options for the filesystem given by the protocol of the URIs of contributing datasets.
186
-
### `slice_engine`
201
+
Extra keyword-arguments passed to a configured `slice_source` together with each slice item.
202
+
203
+
## `slice_engine`
187
204
188
205
Type _string_.
189
206
The name of the engine to be used for opening contributing datasets. Refer to the `engine` argument of the function `xarray.open_dataset()`.
190
-
### `slice_polling`
207
+
208
+
## `slice_storage_options`
209
+
210
+
Type _object_.
211
+
Options for the filesystem given by the protocol of the URIs of contributing datasets.
212
+
213
+
## `slice_polling`
191
214
192
215
Defines how to poll for contributing datasets.
193
216
Must be one of the following:
@@ -212,56 +235,36 @@ Must be one of the following:
212
235
Polling timeout in seconds.
213
236
Defaults to `60`.
214
237
215
-
### `slice_source`
216
-
217
-
Type _string_.
218
-
The fully qualified name of a class or function that receives a slice item as argument(s) and provides the slice dataset. If a class is given, it must be derived from `zappend.api.SliceSource`. If the function is a context manager, it must yield an `xarray.Dataset`. If a plain function is given, it must return any valid slice item type. Refer to the user guide for more information.
219
-
### `slice_source_kwargs`
220
238
221
-
Type _object_.
222
-
Extra keyword-arguments passed to a configured `slice_source` together with each slice item.
223
-
### `persist_mem_slices`
239
+
## `persist_mem_slices`
224
240
225
241
Type _boolean_.
226
242
Persist in-memory slices and reopen from a temporary Zarr before appending them to the target dataset. This can prevent expensive re-computation of dask chunks at the cost of additional i/o.
227
243
Defaults to `false`.
228
-
## Data I/O - Transactions
229
244
230
-
###`temp_dir`
245
+
## `temp_dir`
231
246
232
247
Type _string_.
233
248
The URI or local path of the directory that will be used to temporarily store rollback information.
234
-
### `temp_storage_options`
249
+
250
+
## `temp_storage_options`
235
251
236
252
Type _object_.
237
253
Options for the filesystem given by the protocol of `temp_dir`.
238
-
### `disable_rollback`
239
-
240
-
Type _boolean_.
241
-
Disable rolling back dataset changes on failure. Effectively disables transactional dataset modifications, so use this setting with care.
242
-
Defaults to `false`.
243
-
## Misc.
244
-
245
-
### `version`
246
254
247
-
Configuration schema version. Allows the schema to evolve while still preserving backwards compatibility.
248
-
Its value is `1`.
249
-
Defaults to `1`.
250
-
### `dry_run`
255
+
## `force_new`
251
256
252
257
Type _boolean_.
253
-
If `true`, log only what would have been done, but don't apply any changes.
258
+
Force creation of a new target dataset. An existing target dataset (and its lock) will be permanently deleted before appending of slice datasets begins. WARNING: the deletion cannot be rolled back.
254
259
Defaults to `false`.
255
-
### `permit_eval`
260
+
261
+
## `disable_rollback`
256
262
257
263
Type _boolean_.
258
-
Allow for dynamically computed values in dataset attributes `attrs` using the syntax `{{ expression }}`. Executing arbitrary Python expressions is a security risk, therefore this must be explicitly enabled. Refer to the user guide for more information.
264
+
Disable rolling back dataset changes on failure. Effectively disables transactional dataset modifications, so use this setting with care.
259
265
Defaults to `false`.
260
-
### `extra`
261
266
262
-
Type _object_.
263
-
Arbitrary configuration that is not validated by default. Intended use is by a `slice_source` that expects an argument named `ctx` and therefore can access the configuration.
264
-
### `profiling`
267
+
## `profiling`
265
268
266
269
Profiling configuration. Allows for runtime profiling of the processing.
267
270
Must be one of the following:
@@ -309,7 +312,8 @@ Must be one of the following:
309
312
Pattern-match the standard name that is printed.
310
313
311
314
312
-
### `logging`
315
+
316
+
## `logging`
313
317
314
318
Logging configuration.
315
319
Must be one of the following:
@@ -403,3 +407,14 @@ Must be one of the following:
403
407
The items of the array are of type _string_.
404
408
405
409
410
+
## `dry_run`
411
+
412
+
Type _boolean_.
413
+
If `true`, log only what would have been done, but don't apply any changes.
414
+
Defaults to `false`.
415
+
416
+
## `extra`
417
+
418
+
Type _object_.
419
+
Extra settings. Intended use is by a `slice_source` that expects an argument named `ctx` to access the extra settings and other configuration.
0 commit comments