Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
6889e62
Add the xdas.tiles tile-backed virtual array package
atrabattoni Jul 30, 2026
9650598
Rewire the silixa and miniseed engines onto TileArray
atrabattoni Jul 30, 2026
d653d3e
Persist tile manifests in the xdas format, deprecate dask writes
atrabattoni Jul 30, 2026
227e864
Merge branch 'dev' into feature/tilearray-fallback
atrabattoni Jul 30, 2026
e275d17
Merge the tile engine registry into io.Engine as load_tile
atrabattoni Jul 30, 2026
edb6051
Add an optional tiles vtype to every HDF5 io engine
atrabattoni Jul 30, 2026
f3d3001
Document the tiles vtype and the load_tile plugin half
atrabattoni Jul 30, 2026
4e6cf31
Read febus tiles as one hyperslab instead of per-block reads
atrabattoni Jul 30, 2026
23b4b84
Drop the tiles registry adapter, resolve engines on Engine[name]
atrabattoni Jul 30, 2026
45493ed
Anchor tile paths to absolute at TileArray construction
atrabattoni Jul 30, 2026
b3000b3
Remove the regular-coordinates plan from docs
atrabattoni Jul 30, 2026
76e6644
Read the package version from a single source
atrabattoni Jul 30, 2026
385cc2d
Open 0.2.9 development
atrabattoni Jul 30, 2026
bc100bb
Note the single version source in the release notes
atrabattoni Jul 30, 2026
c80a85e
Merge branch 'dev' into feature/tiles-vtype
atrabattoni Jul 31, 2026
4dc69cc
Raise the multi-file open limit for the tiles vtype
atrabattoni Jul 31, 2026
ecc723a
Reopen data collections of tile-backed arrays
atrabattoni Jul 31, 2026
9360838
Correct how the two virtualization backends compare on reads
atrabattoni Aug 1, 2026
f08de4f
Default Febus to tiles and refresh the I/O documentation
atrabattoni Aug 1, 2026
2969aeb
Fold the open-file limits into one vtype-keyed constant
atrabattoni Aug 1, 2026
57414a9
Make engine configuration explicit across the open functions
atrabattoni Aug 1, 2026
46b88d6
Split the TileArray constructor from the scan-time encoder
atrabattoni Aug 2, 2026
7dcad98
Demote the tile dtype to recorded metadata
atrabattoni Aug 1, 2026
6bd5b7e
Accept a plain engine name as TileArray specification shorthand
atrabattoni Aug 2, 2026
dca625f
Summarize a tile array on one line under its data array
atrabattoni Aug 2, 2026
daa751f
Drop the extract_array helper in favor of plain .data access
atrabattoni Aug 2, 2026
dc7512a
Flatten the single-module tiles package into xdas/tiles.py
atrabattoni Aug 2, 2026
d2010d6
Store tile manifest strings as fixed-width char arrays
atrabattoni Aug 2, 2026
aab8b3d
Split the common source directory out of tile manifest paths
atrabattoni Aug 2, 2026
8638b0c
Return a plain copy of the wrapped dataset from to_dataset
atrabattoni Aug 2, 2026
d969c44
Find the manifest root from the lexicographic path extremes
atrabattoni Aug 2, 2026
e5f2056
Merge branch 'feature/tiles-vtype' into feature/tiles-char-manifest
atrabattoni Aug 2, 2026
6ed73b5
Hold manifest strings as fixed-width bytes in memory
atrabattoni Aug 3, 2026
e631db9
Vectorize the manifest path handling with np.strings
atrabattoni Aug 3, 2026
ac3b020
Lean on Variable.set_dims and inline the streaming row loop
atrabattoni Aug 3, 2026
ccacb8b
Inline the file-count check and name the depth-scan visitor
atrabattoni Aug 3, 2026
d174024
Dispatch the geometry-rewriting numpy routines lazily on TileArray
atrabattoni Aug 3, 2026
7dfeb51
Record an axis map in tile manifests, freeing the engine contract
atrabattoni Aug 3, 2026
e3778f7
Give tile geometry steps a sign for lazy reversal
atrabattoni Aug 3, 2026
d558fd7
Fold the duplicate geometry defaults, streaming mask and one-shot hel…
atrabattoni Aug 3, 2026
afda167
Require equal division from every int-sectioned split but array_split
atrabattoni Aug 3, 2026
9adefff
Condense the 0.2.9 release notes to the user-facing surface
atrabattoni Aug 3, 2026
9983540
Sync the tiles API page with the engine roster
atrabattoni Aug 3, 2026
b27d0c3
Lift the file-count ceiling from tiles scans
atrabattoni Aug 3, 2026
b0ac12f
Replace Douglas-Peucker with a one-pass sleeve in simplify
atrabattoni Aug 3, 2026
1107713
Stream the multi-file combine and sort tiles at the end
atrabattoni Aug 3, 2026
bc014cc
Document the streamed combine
atrabattoni Aug 3, 2026
491c7e9
Bound the scan by one limit the vtype declares
atrabattoni Aug 3, 2026
f749e82
Gather the virtual backends into a package
atrabattoni Aug 4, 2026
519e6ca
Register the virtual backends by vtype
atrabattoni Aug 4, 2026
3aae8f3
Look up backend capabilities from the registry
atrabattoni Aug 4, 2026
a10cf8b
Validate vtype names against the backend registry
atrabattoni Aug 4, 2026
13df141
Repair three tiles imports the package move missed
atrabattoni Aug 4, 2026
9b7bc60
Dispatch the plain-variable wrap through the registry
atrabattoni Aug 4, 2026
486321f
Let the backends write their own stored form
atrabattoni Aug 4, 2026
775503a
Declare the whole backend contract on the base
atrabattoni Aug 4, 2026
72b1493
Promote VirtualBackend to an ABC
atrabattoni Aug 4, 2026
c992d9b
Pin the febus reference read to the hdf5 vtype
atrabattoni Aug 4, 2026
a07c786
Drop Python 3.10 support
atrabattoni Aug 4, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
python-version: ["3.11", "3.12", "3.13", "3.14"]

steps:
- uses: actions/checkout@v4
Expand Down
1 change: 1 addition & 0 deletions docs/api/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,6 @@ processing
signal
synthetics
testing
tiles
virtual
```
65 changes: 65 additions & 0 deletions docs/api/tiles.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
```{eval-rst}
.. currentmodule:: xdas.virtual.tiles
```

# xdas.virtual.tiles

Lazy tile-backed virtual arrays: the only backend of the formats that
HDF5 virtual datasets cannot serve (Silixa TDMS, MiniSEED), the default
one for Febus, and available on request from every other engine
(`vtype="tiles"`).

## TileArray

A dense rectilinear grid of file-backed tiles exposed as one lazy
numpy-like array.

Attributes

```{eval-rst}
.. autosummary::
:toctree: ../_autosummary

TileArray.shape
TileArray.dtype
TileArray.ndim
TileArray.size
TileArray.chunks
TileArray.ntiles
TileArray.engine
TileArray.attrs
```

Methods

```{eval-rst}
.. autosummary::
:toctree: ../_autosummary

TileArray.from_tiles
TileArray.from_variable
TileArray.to_dataset
TileArray.create_variable
TileArray.finalize_save
TileArray.concat
TileArray.expand_dims
TileArray.squeeze
TileArray.transpose
TileArray.astype
TileArray.equals
```

## Engine lookup

Tiles are decoded by the ``load_tile`` half of the
{class}`xdas.io.Engine` format plugins; the engine names stored in tile
manifests resolve on that registry (``Engine[name]``).

```{eval-rst}
.. currentmodule:: xdas.io

.. autosummary::
:toctree: ../_autosummary

Engine.load_tile
```
14 changes: 13 additions & 1 deletion docs/api/virtual.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,20 @@

# xdas.virtual

## VirtualBackend

Marker base and `vtype` registry for the virtual array backends.

```{eval-rst}
.. autosummary::
:toctree: ../_autosummary

VirtualBackend
```

## VirtualArray

Base class for all virtual array types.
Base class of the HDF5 virtual dataset backend (`vtype="hdf5"`).

Attributes

Expand All @@ -28,6 +39,7 @@ Methods
.. autosummary::
:toctree: ../_autosummary

VirtualArray.from_variable
VirtualArray.to_dataset
```

Expand Down
1 change: 1 addition & 0 deletions docs/api/xdas.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
concatenate
concat_coords
get_sampling_interval
sortby
split
plot_availability
```
Expand Down
23 changes: 23 additions & 0 deletions docs/release-notes.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,28 @@
# Release notes

## 0.2.9 (unreleased)

### New Features
- **Tile-backed virtual arrays.** The new `xdas.virtual.tiles` module exposes file archives as one lazy `TileArray`. Slicing (any step, including negative), integer indexing, `np.newaxis`, concatenation, and the numpy manipulation routines (the `transpose`, `flip`, `split`, `stack` and `atleast` families, `expand_dims`, `squeeze`, `roll`, `tile`, `delete`, `append`/`insert`) all stay lazy; whole-array reductions (`sum`, `mean`, `min`, `max`, …) stream one tile row at a time; reads touch only the tiles the selection overlaps (@atrabattoni).
- **`vtype="tiles"` on every HDF5 engine.** The open functions with `vtype="tiles"` return tile-backed arrays for the asn, febus, terra15, apsensing, prodml and native xdas engines. Silixa and MiniSEED always emit them now (replacing the serialized-dask-graph fallback, with time-axis push-down for Silixa), and Febus defaults to them — one tile per file, where the HDF5 backing needed one virtual mapping per data block. Custom engines add support by implementing `Engine.load_tile(path, selection, **params)` (@atrabattoni).
- Tile-backed arrays round-trip through the native xdas netCDF format: the manifest is stored as a compact `__tiles__` sibling group, relocatable by editing its single root path and directly readable by the 0.3 line (@atrabattoni).
- **Explicit engine configuration.** The open functions declare `engine`, `vtype` and `ctype`, and `engine` also accepts a configured `xdas.io.Engine` instance. Format-specific parameters (`overlaps`/`offset` for febus, `ignore_last_sample` for miniseed, `swapped_dims` for prodml, `tz` for terra15, `group` for the native format) are engine constructor parameters, validated up front (@atrabattoni).
- `open_mfdataarray` no longer caps the number of files when the resolved vtype consolidates its scan results, which `tiles` does; the 100 000 ceiling remains for `hdf5`, which builds one virtual mapping per file and so cannot be fused into anything smaller (@atrabattoni).
- **Streamed multi-file combining.** `open_mfdataarray` now fuses scan results every 100 000 files instead of holding one data array per file until the end, so memory no longer grows with the archive: results are accumulated without coordinate simplification (lossless in any arrival order) and sorted once at the end, giving the same result as before whatever the file naming. Acquisitions interleaved in time now group by compatibility, one array per acquisition, instead of splitting at each alternation. Since the batch size is also the ceiling, anything that opened in one call before still takes the single-batch path unchanged (@atrabattoni).
- **`xdas.sortby`.** Sort a tile- or stack-backed data array along a dimension by coordinate value, lazily: the blocks are permuted through the manifest without reading any data. This is how the streamed combine orders shuffled archives, exposed for standalone use (@atrabattoni).
- `simplify` runs in linear time whatever the number of gaps: the reduce stage is now a one-pass sleeve instead of Douglas-Peucker, which degenerated quadratically on gap-rich coordinates (a 100 000-file gappy archive simplified in minutes; now milliseconds). The deviation guarantee is unchanged — dropped tie points stay within `tolerance` of the curve, surviving values never move — though the surviving tie-point selection may differ slightly on jittery axes (@atrabattoni).

### Breaking Changes
- Python 3.10 support is dropped and the numpy requirement is raised to 2.3: the tile manifests use `np.strings` routines introduced in numpy 2.3, which itself requires Python 3.11+. Python 3.10 reaches end of life in October 2026 (@atrabattoni).
- Passing a bare read function as `engine` now raises a `TypeError`: subclass `xdas.io.Engine` instead (see the data-formats documentation) (@atrabattoni).
- Misspelled or unsupported keyword arguments passed next to an engine name now raise a `TypeError` instead of being silently ignored, and combining `vtype`, `ctype` or engine keywords with an already configured engine instance raises a `ValueError` (@atrabattoni).

### Deprecations
- Writing dask-backed virtual arrays is deprecated and emits a `FutureWarning`; existing files still open, but no engine emits them any more (@atrabattoni).

### Bug Fixes
- The miniseed `ctype` argument is now honored: it previously routed to an unused attribute and the reader always built interpolated time coordinates. The default is unchanged (@atrabattoni).

## 0.2.8

### New Features
Expand Down
8 changes: 5 additions & 3 deletions docs/user-guide/coordinates/interpolated-coordinates.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,10 @@ Gaps represent missing data and are generally not problematic; overlaps
usually arise from labelling errors and should be resolved.

Using the {py:meth}`~xdas.coordinates.InterpCoordinate.simplify` method,
the coordinate can be compressed with controlled accuracy using the
[Ramer–Douglas–Peucker algorithm][RDP]. In the example below, the
the coordinate can be compressed with controlled accuracy using a
one-pass [sleeve algorithm][SDT] (tie points are dropped as long as the
segment joining the surviving neighbours passes within `tolerance` of
them, in a single left-to-right walk). In the example below, the
second tie point carries no additional information and is safely discarded:

```{code-cell}
Expand Down Expand Up @@ -162,4 +164,4 @@ coord.to_index(slice("2023-01-01T00:10:00", "2023-01-01T00:20:00"))
```

[CF]: <http://cfconventions.org/Data/cf-conventions/cf-conventions-1.10/cf-conventions.html#compression-by-coordinate-subsampling>
[RDP]: <https://en.wikipedia.org/wiki/Ramer–Douglas–Peucker_algorithm>
[SDT]: <https://en.wikipedia.org/wiki/Swinging_door_algorithm>
Loading
Loading