You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat: read puck, position and run from the file name (UC-1.3) #9
As the beamline scientist, I want every result to say which puck and position it belongs to, for example "Puck A, position 07".
Proposed solution
parse_sample_id(path, pattern=None) returns SampleId(puck, position, run), which has a sample_id property.
Default pattern matches L_A07_0007_master.h5: puck A, position 07, run 0007, sample_id A07. The pattern is a setting, because the beamline scientist has not confirmed the naming yet.
No match gives puck, position and run as None and sample_id unknown.
str(sample_id) gives "Puck A, position 07, run 0007".
Done when
Parametrized tests: real-style names, testcrystal_0008_master.h5, a custom pattern
Activity