Identifies, formalizes, and prioritizes data access patterns for Zarr datasets from user workflows. Maps to xarray operations for chunk optimization benchmarking.
npx claudepluginhub uw-ssec/rse-plugins --plugin zarr-chunk-optimizationThis skill uses the workspace's default tool permissions.
Access pattern analysis is the foundation of effective chunk optimization. The shape and size of Zarr chunks must reflect how data is actually read -- not how it is stored or how it was originally written. A chunk layout optimized for spatial queries will punish temporal access with orders-of-magnitude slowdowns, and vice versa. Before running any benchmark, you must know which access patterns ...
Generates design tokens/docs from CSS/Tailwind/styled-components codebases, audits visual consistency across 10 dimensions, detects AI slop in UI.
Records polished WebM UI demo videos of web apps using Playwright with cursor overlay, natural pacing, and three-phase scripting. Activates for demo, walkthrough, screen recording, or tutorial requests.
Delivers idiomatic Kotlin patterns for null safety, immutability, sealed classes, coroutines, Flows, extensions, DSL builders, and Gradle DSL. Use when writing, reviewing, refactoring, or designing Kotlin code.
Access pattern analysis is the foundation of effective chunk optimization. The shape and size of Zarr chunks must reflect how data is actually read -- not how it is stored or how it was originally written. A chunk layout optimized for spatial queries will punish temporal access with orders-of-magnitude slowdowns, and vice versa. Before running any benchmark, you must know which access patterns matter, how often each occurs, and how to express them as concrete xarray operations. Skipping this step means benchmarking against the wrong workload, which produces chunk configurations that feel fast in testing and fail in production.
| Resource | Purpose |
|---|---|
references/pattern-identification.md | Deep reference on spatial, temporal, spectral, and diagonal access patterns with domain examples |
references/workflow-mapping.md | Translating user descriptions and xarray operations into formal pattern definitions |
assets/pattern-definitions-template.json | JSON template for defining benchmark-ready access patterns with weights |
assets/workflow-questionnaire.md | Structured interview questions to elicit access patterns from users |
| Pattern | Typical Slice Shape | Example xarray Operation | Dominant Dimension |
|---|---|---|---|
| Spatial | (1, lat, lon) | ds.sel(time="2020-01-01") | lat, lon |
| Temporal | (time, 1, 1) | ds.sel(lat=45.0, lon=-90.0) | time |
| Spectral | (1, 1, freq) | ds.sel(time="2020-01-01", lat=45.0) | frequency/channel |
| Diagonal | (time_sub, lat_sub, lon_sub) | ds.sel(time=slice(...), lat=slice(...)) | multiple partial |
Spatial access retrieves a full 2D (or higher-dimensional) spatial field at a single point in another dimension, typically time. This is the most common pattern in visualization, mapping, and spatial analysis.
Time axis: [T0] [T1] [T2] [T3] ...
|
v
+--+--+--+--+
| | | | | Entire lat/lon plane
+--+--+--+--+ at one timestep
| | | | |
+--+--+--+--+
Ideal chunk shape: Large spatial dimensions, small time dimension (e.g., (1, 256, 256)).
Common xarray operations:
ds.sel(time="2020-06-15") -- single timestep mapds.isel(time=0) -- first timestepds.sel(time="2020-06-15").plot() -- visualizationTemporal access retrieves a full time series at a single spatial location or small spatial region. This pattern dominates trend analysis, station-based validation, and point forecasting.
Lat/Lon grid:
+--+--+--+--+
| | | | |
+--+--+--+--+
| | X| | | Single pixel, all timesteps
+--+--+--+--+
|
v
[T0, T1, T2, T3, T4, T5, ...]
Ideal chunk shape: Large time dimension, small spatial dimensions (e.g., (1000, 1, 1)).
Common xarray operations:
ds.sel(lat=45.0, lon=-90.0) -- point time seriesds.sel(lat=45.0, lon=-90.0).resample(time="1M").mean() -- monthly means at a pointds.sel(lat=45.0, lon=-90.0).groupby("time.year") -- annual groupingSpectral access retrieves data across a frequency, wavelength, or channel dimension at a fixed spatial and/or temporal position. This pattern appears in radio astronomy, hyperspectral remote sensing, and multi-band analysis.
Frequency axis:
[F0] [F1] [F2] [F3] [F4] ...
| | | | |
v v v v v
All frequencies at one (time, position) point
Ideal chunk shape: Large frequency dimension, small spatial and time dimensions (e.g., (1, 1, 1, 4096)).
Common xarray operations:
ds.sel(time="2020-01-01", lat=45.0, lon=-90.0) -- full spectrum at a pointds.mean(dim=["lat", "lon"]) -- spatially averaged spectrumThe goal is to translate informal workflow descriptions into one or more formal access patterns. Use the questionnaire in assets/workflow-questionnaire.md and listen for keyword signals:
| User Says | Likely Pattern |
|---|---|
| "I make maps" / "I visualize fields" | Spatial |
| "I look at trends over time" / "time series at stations" | Temporal |
| "I compare across bands" / "spectral analysis" | Spectral |
| "I compute regional averages over time" | Mixed (spatial + temporal) |
| "I do anomaly detection on subregions" | Diagonal |
Once identified, translate each pattern into a concrete xarray slicing operation that benchmarks can execute repeatedly. Use the template in assets/pattern-definitions-template.json.
A well-formed pattern definition includes:
spatial_single_timestep)When a dataset serves multiple access patterns, assign weights based on:
Example weighting for a climate reanalysis dataset:
| Pattern | Frequency | Users | Weight |
|---|---|---|---|
| Spatial (daily maps) | 50/day | 20 | 0.60 |
| Temporal (station validation) | 10/day | 5 | 0.25 |
| Diagonal (regional monthly means) | 2/day | 3 | 0.15 |
When no single chunk shape satisfies all patterns:
references/pattern-identification.md -- Detailed guidance on identifying and classifying access patterns across scientific domains.references/workflow-mapping.md -- Techniques for translating user workflows and xarray operations into formal pattern definitions.assets/pattern-definitions-template.json -- Ready-to-use JSON template for defining weighted access patterns.assets/workflow-questionnaire.md -- Structured questionnaire for eliciting access patterns from users and stakeholders.