feat(array): pa.shape_struct returns any carrier with ShapeDtypeStruct data, for eval_shape and planning
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 57/100
Direzione di ricerca
Start by reading the carrier pytree registrations and the existing adapter code in pipekit-array; the issue proposes using jax.tree.map and says the adapter’s rewrap is not needed. Check the existing tests for DimArray, CField, and jax.eval_shape to locate where to add coverage. Done means reductions on pa.shape_struct(x) preserve the expected dims and shape for both carriers, with lint, type checks, and tests green.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem / Request
Add pa.shape_struct(x), which returns the same carrier with every leaf replaced by a jax.ShapeDtypeStruct, so a pipeline can plan its outputs with jax.eval_shape before any data exists.
Motivation
The prototype built DimArray and CField on a ShapeDtypeStruct((3, 64, 64), float32) and jax.eval_shape of a mean over time gave dims ('y', 'x'). Nothing builds such a carrier from an existing one. coordax has shape_struct_field (CP-D8).
Proposed API
# Shapes: (time, y, x) = (3, 64, 64)
# proposed (CP-D8)
# carrier → the same carrier, leaves as ShapeDtypeStruct
spec = pa.shape_struct(x)
# today (pipekit-array)
# DimArray (time, y, x) → DimArray (y, x)
out = jax.eval_shape(lambda f: pa.reduce(f, jnp.mean, "time"), spec)
Reuse
jax.tree.mapover the carrier's pytree registration; the adapter'srewrapis not needed.
References & Existing Code
- Design:
docs/design/coordax_carriers.mdin jejjohnson/geostack (merged in jejjohnson/geostack#368), pattern 7. - Prototype:
q3_q7_rest.py, section Q7.
Definition of Done
-
eval_shapeof a reduction onpa.shape_struct(x)gives the dims and shape of running it, forDimArrayandCField. - Lint, type check and tests green.
Relationships
- Parent: jejjohnson/geostack#369
- Blocks: jejjohnson/geotoolz#853
- Lingua principale
- Python
- Stelle
- 0
- Fork
- 0
- Merge medio
- 3h 50m
- PR unite (30g)
- 143
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di jejjohnson/pipekit
-
area:code layer:0-primitives priority:p2 type:feature
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
jejjohnson/pipekit#296 ·
I maintainer di solito rispondono entro 1 giorno
-
area:code type:feature
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
jejjohnson/pipekit#410 ·
I maintainer di solito rispondono entro 1 giorno
-
area:code type:feature
Difficoltà 5/5 Più di una settimana Idoneità per principianti 38/100
jejjohnson/pipekit#409 ·
I maintainer di solito rispondono entro 1 giorno
-
area:code type:feature
Difficoltà 3/5 1-2 giorni Idoneità per principianti 75/100
jejjohnson/pipekit#408 ·
I maintainer di solito rispondono entro 1 giorno
-
area:code type:feature
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
jejjohnson/pipekit#407 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di jejjohnson/pipekit
Issue simili
-
A JSON chat answer blocks the backend event loop for the whole RAG runForse già presa @NopeCharon l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
The-OpenROAD-Project/ORAssistant#656 ·
I maintainer di solito rispondono entro 1 giorno
-
bug(operator): VolterraOperator built inside jax.jit with a concrete decay raises TracerBoolConversionErrorForse già presa @jejjohnson l’ha presa oggi. Apertatype:bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
jejjohnson/integrix#144 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
finos/ai-governance-framework#459 ·
-
slurm: a case outcome nested too deep crashes status/collect instead of reading as no outcomeAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
autowarefoundation/autoware_carla_scenario#2963 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
I maintainer di solito rispondono entro 1 giorno