lightsources / BES-XPCS-Pilot

Work with BES Data Science Team to develop Python code to write NeXus data file with proposed NeXus definitions.
0 stars 0 forks source link

frame_sum and frame_average #44

Closed ambarb closed 3 years ago

ambarb commented 3 years ago
prjemian commented 3 years ago

follow: https://github.com/nexusformat/definitions/issues/932

prjemian commented 3 years ago

NeXus intends to add NX_COUNT (singular) to the list of unit types.

JulReinhardt commented 3 years ago

So will we not simply use "counts" as unit here?

prjemian commented 3 years ago

We can continue to use units="counts" here as I believe NeXus will approve the addition of NX_COUNTS as a units type. The pint package recognizes "counts" as a kind of units.

The NeXus issue (https://github.com/nexusformat/definitions/issues/932) is scheduled for consideration at the next NIAC meeting (Sept or Oct this year). This issue was discussed at the NeXus teleconference this week (2021-07-28).

ambarb commented 3 years ago

@prjemian updated us on this state of things in the NX community - they are willing to consider, but the preferences is based on real use cases , like ours.

for our case, do we want to require a label?
@ambarb find out what XPCS community wants (counts, counts per second) for average or sum list.

JulReinhardt commented 3 years ago

Note: currently frame_sum and frame_average are of units NX_ANY same for g2 and and two_time_corr_func. What's the latest decision?

Apart from that this issue is ready to be closed (automatically) once PR is approved.

ambarb commented 3 years ago

these probably should be total counts but we have no way of know if someone decides to divide by exposure time to get "per sec" to understand the count rate. Could we include a note that ideally it seems "counts" would be the best unit of measurement, but we are not stopping people from per sec or even using ADU?

ambarb commented 3 years ago

also note, some related discussion in #63 for a full picture.

ambarb commented 3 years ago

I will find out what the community wants in the meantime, but I think no one is going to want to force units. Sending email out now.

prjemian commented 3 years ago

Could we include a note that ideally it seems "counts" would be the best unit of measurement

This is good content for the documentation.

ambarb commented 3 years ago

units will be NX_COUNT and pretend that it is a standard definition in NX so once this unit label attribute is added here(to our current PR), we can move this to complete.

prjemian commented 3 years ago

This is part of PR#52.