-
Notifications
You must be signed in to change notification settings - Fork 2
Update to use the new tof lookup table workflow #190
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes look good. Can you update the lower pin?
Also, did you check whether https://github.com/scipp/essdiffraction/blob/main/tools/dream-make-tof-lookup-table.ipynb still works?
No, and that is an issue I was wondering about... how do we ensure these notebooks don't get out of date? Edit: I now moved the notebook inside the docs, and use a smaller number of neutrons. |
| " choppers=disk_choppers, neutrons=5_000_000, source_position=sc.vector([0, 0, 0], unit='m'),\n", | ||
| ")\n", | ||
| "\n", | ||
| "wf[time_of_flight.NumberOfSimulatedNeutrons] = 200_000 # Increase this number for more reliable results\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add to the docs (here or in data.py) the number used for the table? Or is it encoded in the hdf5 file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It isn't. We should probably make it a coordinate, like the other metadata?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but it should be unaligned.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm that said, it's something specific to Tof. It's actually the neutrons that were in the source, not the neutrons that make it to the detectors.
If the simulation is done with mcstas, with parameter should not be there.
The other parameters (distamce and time resolution, etc.) belong with the table.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True. But it can still be good to encode this kind of metadata in the file. But that is a longer discussion as we know...
For now, just add it to the docs so we can reproduce it later.
This is a necessary update after scipp/essreduce#253
Only the tests were updated, as the main mode of operation is to use a lookup table read from a file.