Skip to content

Commit

Permalink
Merge pull request #76 from ETSInitiative/DetectorIdType
Browse files Browse the repository at this point in the history
introduce DetectorId type
  • Loading branch information
KrisThielemans authored Dec 13, 2024
2 parents eb60569 + d43a6c6 commit 1315c39
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 5 deletions.
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
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

0 comments on commit 1315c39

Please sign in to comment.