Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

introduce DetectorId type #76

Merged
merged 2 commits into from
Dec 13, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions model/CoincidenceEvent.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# All information about a coincidence event specified as identifiers or indices (i.e. discretized). Indices start from 0.
# All information about a coincidence event specified as identifiers (i.e. discretized).
# TODO: this might take up too much space, so some/all of these could be combined in a single index if necessary.
CoincidenceEvent: !record
fields:
# the pair of detector elements
detectorIds: uint*2
# identifiers of the two detecting elements (see doc for DetectorId)
detectorIds: DetectorId*2
# an index into the tofBinEdges field in the ScannerInformation
tofIdx: uint
# a pair of indices into the energyBinEdges field in the ScannerInformation
Expand Down
12 changes: 12 additions & 0 deletions model/DetectorInformation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,15 @@ ScannerGeometry: !record
ids: uint*
# shielding etc
nonDetectingVolumes: GenericSolidVolume*?

# This is the type for detector IDs using in `CoincidenceEvent` and `TripleEvent`.
# It is an unsigned integer that runs over all the "elementary detector elements" (aka crystals),
# starting from 0.
# The correspondence between this integer and a module/det_el is not decided (TODO),
# but the current proposal is to effectively increment the detectorID in nested loops:
# 1. ScannerGeometry.replicated_modules
# 2. replicated_module.transforms
# 3. replicated_module.detecting_elements
# 4. detecting_element.transforms
# (with therefore the detector IDs running faster over the 4th loop)
DetectorID: uint
KrisThielemans marked this conversation as resolved.
Show resolved Hide resolved
7 changes: 5 additions & 2 deletions model/TripleEvent.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# All information about a triple event specified as identifiers or indices (i.e. discretized).
# All information about a triple event specified as identifiers (i.e. discretized).
TripleEvent: !record
fields:
detectorIds: uint*3
# Identifiers of the three detecting elements (see doc for DetectorId)
# Note that it is possible that 2 detectorIDs are equal (e.g. for
# inter-crystal Compton events)
detectorIds: DetectorId*3
# timing differences (converted to mm) w.r.t. first event, stored as
# indices into the tofBinEdges field in the ScannerInformation
# Note: only 2, corresponding to the arrival time differences of the second and third detectorId
Expand Down
Loading