scipp / scipp/ess

Find a reference time for computing pulse_index

Open
#95 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

essreduce
Dominant language
Python
Stars
1
Forks
3
Avg merge
2d 11h
Merged PRs (30d)
17

Description

See https://github.com/scipp/essreduce/pull/180#discussion_r1949052455 for context.

When doing pulse-skipping, We need a reliable way to define a reference start time of the run, so we can determine to which pulse in a stride the events are coming from.
The reference time needs to be fixed, in case the data comes in in chunks (cannot simply use the min event_time_offset for each new piece of data).
Some pulses might have no events, so pulses are not always consecutive.

Using a global reference like epoch may work, but it seems difficult to know only from that if the filewriter started recording in the middle of a frame, or at the start of a frame.

It seems the only way would be to look at the open/close times of the pulse-skipping chopper and determine pulse indices from that.
This sounds complicated as we would need to flag which is the pulse-skipping chopper, propagate the open-close times back to the source, and assign pulse indices. The open-close times would need to be in the global timing reference, probably using the chopper TDC time stamps...

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked pull request discussion and trace the pulse-skipping logic that computes pulse_index. Determine how a fixed run reference can remain consistent across data chunks and missing pulses, then verify that pulse indices can be assigned using the available chopper timing information.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.