Skip to content

[AGIPD][DARK] Sort dark runs

Karim Ahmed requested to merge feat/sort_dark_runs_agipd2 into master

Description

This is the second and last piece for sorting AGIPD dark runs

  • Remove validate_gain_runs() function and moving needed error to new function.
  • Create new function to sort dark runs.
  • Add tests for the new function and remove tests for removed function
  • Sort dark runs in Dark notebook before reading conditions.

Sorting dark runs

Expected patterns to use for sorting dark runs are:

  • XRay: 0, DarkHG: 1, DarkMG: 2, DarkLG: 3, PC: 4, and CS: 5.

For Adaptive gain mode: All 3 runs have XRay patterns. On the other hand for fixed gain mode we expected DarkHG, DarkMG, and DarkLG patterns

Adaptive mode

For AGIPD1M patterns can be checked from ctrl_src/patternTypeIndex for the integer value or ctrl_src/patternType for the string value. However, AGIPD500K patterns can be checked from ctrl_src/expTypeIndex with integer value or expType for the string value.

Fixed Mode

Run order for fixed gain can only be decided using the gain modes.

How Has This Been Tested?

  • TBD

Relevant Documents (optional)

Types of changes

  • New feature (non-breaking change which adds functionality)
  • Test (additional or refactored tests)

Checklist:

  • A calibration_configuration updated for the know old proposals for AGIPD500K with sort_runs = False : An MR has the changes. To be merged with the next release

Reviewers

@kluyvert @schmidtp

Edited by Karim Ahmed

Merge request reports