public abstract class AbstractSvtEvioReader extends EvioReader
RawTrackerHit
s.Modifier and Type | Field and Description |
---|---|
protected Map<Pair<Integer,Integer>,HpsSiSensor> |
daqPairToSensor |
protected boolean |
isDaqMapSetup |
static Logger |
LOGGER |
private static String |
READOUT_NAME |
private static String |
SUBDETECTOR_NAME |
static String |
SVT_HEADER_COLLECTION_NAME |
private static String |
SVT_HIT_COLLECTION_NAME |
debug, hitCollectionName
Constructor and Description |
---|
AbstractSvtEvioReader() |
Modifier and Type | Method and Description |
---|---|
protected void |
checkSvtSampleCount(int sampleCount,
SvtHeaderDataInfo headerData)
Checks that the SVT header data count is consistent with the bank size.
|
protected int |
extractMultisampleHeaderData(int[] samples,
int index,
int[] multisampleHeaderData)
Copy the multisample header data for the samples into a long array.
|
protected SvtHeaderDataInfo |
extractSvtHeader(int num,
int[] data)
Extract the header information and store it in a
SvtHeaderDataInfo object. |
protected abstract int |
getDataHeaderLength()
Get the number of 32 bit integers composing the data block header
|
protected abstract int |
getDataTailLength()
Get the number of 32 bit integers composing the data block tail (the
data inserted after all sample blocks in a data block)
|
protected abstract int |
getMaxDataBankTag()
Get the maximum SVT ROC bank tag in the event.
|
protected abstract int |
getMaxRocBankTag()
Get the maximum SVT ROC bank tag in the event.
|
protected abstract int |
getMinDataBankTag()
Get the minimum SVT ROC bank tag in the event.
|
protected abstract int |
getMinRocBankTag()
Get the minimum SVT ROC bank tag in the event.
|
protected abstract int |
getRocBankNumber()
Get the SVT ROC bank number of the bank encapsulating the SVT samples.
|
protected abstract HpsSiSensor |
getSensor(int[] data)
Get the sensor associated with a set of samples
|
protected abstract boolean |
isValidSampleSet(int[] data)
Check whether the samples are valid
|
protected abstract org.lcsim.event.RawTrackerHit |
makeHit(int[] data)
Make a
RawTrackerHit from a set of samples. |
protected org.lcsim.event.RawTrackerHit |
makeHit(int[] data,
int channel)
Make a
RawTrackerHit from a set of samples. |
boolean |
makeHits(org.jlab.coda.jevio.EvioEvent event,
org.lcsim.event.EventHeader lcsimEvent)
Make
RawTrackerHit s out of all sample sets in an SVT EVIO bank
and put them into an LCSim event. |
boolean |
processEvent(org.jlab.coda.jevio.EvioEvent event,
org.lcsim.event.EventHeader lcsimEvent)
Process an EVIO event and extract all information relevant to the SVT.
|
protected abstract void |
processSvtHeaders(List<SvtHeaderDataInfo> headers,
org.lcsim.event.EventHeader lcsimEvent)
Process the headers that were extracted from the SVT data.
|
protected void |
setMultiSampleHeaders(SvtHeaderDataInfo headerData,
int n,
int[] multisampleHeaders)
Add the multisample headers to the
SvtHeaderDataInfo object. |
protected abstract void |
setupDaqMap(org.lcsim.geometry.Subdetector subdetector)
A method to setup a mapping between a DAQ pair
(FPGA/Hybrid or FEB ID/FEB Hybrid ID) and the corresponding sensor.
|
setDebug, setHitCollectionName
public static final String SVT_HEADER_COLLECTION_NAME
public static final Logger LOGGER
protected Map<Pair<Integer,Integer>,HpsSiSensor> daqPairToSensor
protected boolean isDaqMapSetup
private static final String SVT_HIT_COLLECTION_NAME
private static final String SUBDETECTOR_NAME
private static final String READOUT_NAME
protected abstract int getMinRocBankTag()
protected abstract int getMaxRocBankTag()
protected abstract int getMinDataBankTag()
protected abstract int getMaxDataBankTag()
protected abstract int getRocBankNumber()
protected abstract int getDataHeaderLength()
protected abstract int getDataTailLength()
protected abstract void setupDaqMap(org.lcsim.geometry.Subdetector subdetector)
subdetector
- - The tracker Subdetector
objectprotected abstract HpsSiSensor getSensor(int[] data)
data
- - sample block of dataprotected abstract boolean isValidSampleSet(int[] data)
data
- : sample block of datapublic boolean processEvent(org.jlab.coda.jevio.EvioEvent event, org.lcsim.event.EventHeader lcsimEvent) throws SvtEvioExceptions.SvtEvioReaderException
event
- - EVIO event to processlcsimEvent
- - LCSim event to put collections intoSvtEvioExceptions.SvtEvioReaderException
public boolean makeHits(org.jlab.coda.jevio.EvioEvent event, org.lcsim.event.EventHeader lcsimEvent) throws SvtEvioExceptions.SvtEvioReaderException
RawTrackerHit
s out of all sample sets in an SVT EVIO bank
and put them into an LCSim event.makeHits
in class EvioReader
event
- - EVIO event to processlcsimEvent
- - LCSim event to put collections intoSvtEvioExceptions.SvtEvioReaderException
protected abstract void processSvtHeaders(List<SvtHeaderDataInfo> headers, org.lcsim.event.EventHeader lcsimEvent) throws SvtEvioExceptions.SvtEvioHeaderException
headers
- - list of all headerslcsimEvent
- - the current LCSIM event being processedSvtEvioExceptions.SvtEvioHeaderException
protected SvtHeaderDataInfo extractSvtHeader(int num, int[] data)
SvtHeaderDataInfo
object.num
- - bank num (ROC id)data
- - SVT data block.SvtHeaderDataInfo
.protected int extractMultisampleHeaderData(int[] samples, int index, int[] multisampleHeaderData)
samples
- index
- multisampleHeaderData
- protected void checkSvtSampleCount(int sampleCount, SvtHeaderDataInfo headerData) throws SvtEvioExceptions.SvtEvioHeaderException
sampleCount
- - sample count from the size.headerData
- - header extracted from the bank.SvtEvioExceptions.SvtEvioHeaderException
protected void setMultiSampleHeaders(SvtHeaderDataInfo headerData, int n, int[] multisampleHeaders)
SvtHeaderDataInfo
object.headerData
- - object to add multisample headers to.n
- - number of multisample headersmultisampleHeaders
- - multisample headers to copyprotected abstract org.lcsim.event.RawTrackerHit makeHit(int[] data)
RawTrackerHit
from a set of samples.data
- : sample block of dataprotected org.lcsim.event.RawTrackerHit makeHit(int[] data, int channel)
RawTrackerHit
from a set of samples.data
- : Sample block of datachannel
- : Channel number associated with these samplesCopyright © 2019. All rights reserved.