-
|
Hello, However I would also like to save it together with any data that is being saved by the detector (either by daq logger, daq scan, or just save button). I thought of including it to the list of DataFromPlugins (with do_plot=False) but this means we'll just save many copies of the background, for instance at each scan position. Another way would be to store it in the parametertree of the detector (hidden, probably), but I don't know which Parameter type would support an np.ndarray! Has anyone already tried something similar? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
|
Various questions arises:
|
Beta Was this translation helpful? Give feedback.
-
|
Yes, the viewer outputs several data: two images (or spectra if full vertical binning) corresponding to "pump on" or "off", then another one with the resulting dA/A, +possibly other things depending on options, like the timestamps of each image. It also does things differently depending on whether you want to see each acquisition, or if you treat incoming data by chunk. Another thing is that there is actually two backgrounds, for on and off spectra (because of pump scattering). The h5file seems like a good idea, especially since the filename will be saved in the parametertree so we will be able to match each dataset with its proper background file. Thanks! |
Beta Was this translation helpful? Give feedback.
-
|
We were indeed able to solve the problem using an h5file, thanks! For reference, some details: this is what the save function looks like: To be able to use the add_data method right away, I had to add two attributes to the plugin |
Beta Was this translation helpful? Give feedback.

We were indeed able to solve the problem using an h5file, thanks!
For reference, some details:
When we take the backgrounds, they are also saved to an h5file. The name of this file is saved as a read-only parameter of the plugin. This way, any data that is taken will have a "link" to the correct background that is in use.
this is what the save function looks like: