[ESSSPECTROSCOPY] `save_sqw` writes `u = [1,0,0]`, `v = [0,1,0]` whatever the crystal's orientation

Aperta
#926 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
48/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
python
Ambito
data

Direzione di ricerca

Start with ess/bifrost/io/sqw.py, especially _AXIS_U and _AXIS_V and the code that writes the projection and run headers. Trace how the sample orientation and the U and B matrices are represented before deciding how to convert the pixels into crystal coordinates. Done means save_sqw writes sample-derived u and v in rlu so cuts reflect the crystal mounting.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

essspectroscopy

_AXIS_U and _AXIS_V (ess/bifrost/io/sqw.py:27-28) are written into the projection and into every run header, in 1/Å rather than rlu. The pixels are sample-table momenta (z along the beam, y up), which are Horace's crystal Cartesian frame only for a crystal mounted with a*, b*, c* along x, y, z at a3 = 0. Even then the header is wrong: it says a* is along the beam. Any other mounting gives rotated cuts with no warning.

Suggestion: take u and v from the sample, convert the pixels with the U and B matrices, and write u and v in rlu.

Checked on scipp 26.11.0, scippneutron 26.10.0, essreduce 26.11.1, essspectroscopy 26.11.3.

Lingua principale
Python
Stelle
3
Fork
6
Merge medio
2g 13h
PR unite (30g)
35

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di scipp/ess

Tutte le issue di scipp/ess

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.