Gaps found by the Panel outputs prototype

Abierto
#124 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
45/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
jupyter, python

Línea de trabajo

Start with docs/developer/roles/spec-form.ipynb on the spec-form-outputs branch and inspect the five gaps recorded in the issue. The issue says the prototype works around them and identifies #81 for the completion notification; first determine which gap is in scope. Done means addressing a selected gap, with the prototype behavior improved as described.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Gaps found while adding an outputs list and plotting to the Panel prototype (docs/developer/roles/spec-form.ipynb, branch spec-form-outputs). The app lists a row per output of each record, shows what the output is and how it was made, and plots arrays with plopp. None of these block the prototype.

1. A value's summary reads the whole value

To show an output's sizes, unit and coordinates, the app calls client.output(record, name), which copies the whole value. No call returns this without the data:

value = client.output(record, 'counts')  # copies the whole array
f'{value.dims} {value.shape} [{value.unit}]'

In this process the cost is small. For the hosted service (#27), listing or inspecting outputs would transfer every value.

2. The spec doesn't declare an array's number of dimensions

The spec declares sc.Variable or sc.DataArray, but not how many dimensions. ForwardOutputs.i0 is declared as an array, so the app offers Plot, but its value is 0-D. The app only finds out after reading it and shows "0-D, not plotted". The same holds for arrays with more than 2 dimensions.

3. Nothing tells the app that a record finished

The app submits without waiting, then polls client.status every 0.5 s through a Panel periodic callback (App.poll). The missing as_completed / timeout= is already listed in #81. In the prototype, each finished record also rebuilds the pickers of every form, since a form offers each record as a reference.

4. A workflow can't learn a run's number from its file model

A file's identity is opaque to the workflow. toy_sans.COUNTS outputs a (run, pixel) array, but cannot give the run dimension a coordinate with the run numbers, so the plot labels runs by index.

5. Default titles from field names read poorly

places.title turns iofq into "Iofq". The spec author can set Field(title=...), so this needs nothing from the framework, but the toy specs and examples should set titles (and description=) on outputs.

Lenguaje dominante
Python
Estrellas
0
Forks
1
Merge medio
15 h 25 min
PR fusionados (30 d)
60

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de scipp/essapps

Todos los issues de scipp/essapps

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.