Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Corryvreckan
Corryvreckan
Commits
586dd8f2
Commit
586dd8f2
authored
May 12, 2017
by
CLICdp user
Browse files
push telescope changes
Former-commit-id: 8723f43a4d4263846c071718f77c06f59bb3fbe8
parent
03214085
Changes
6
Hide whitespace changes
Inline
Side-by-side
branches/trunk/algorithms/Alignment.C
View file @
586dd8f2
...
...
@@ -5,8 +5,8 @@
Alignment
::
Alignment
(
bool
debugging
)
:
Algorithm
(
"Alignment"
){
debug
=
debugging
;
m_numberOfTracksForAlignment
=
20000
0
;
nIterations
=
5
;
m_numberOfTracksForAlignment
=
20000
;
nIterations
=
3
;
}
// Global container declarations
...
...
branches/trunk/algorithms/GUI.C
View file @
586dd8f2
...
...
@@ -78,7 +78,7 @@ void GUI::initialise(Parameters* par){
}
// Set event counter
eventNumber
=
0
;
eventNumber
=
1
;
}
...
...
@@ -90,9 +90,15 @@ StatusCode GUI::run(Clipboard* clipboard){
canvases
[
iCanvas
]
->
Paint
();
canvases
[
iCanvas
]
->
Update
();
}
eventNumber
++
;
}
gSystem
->
ProcessEvents
();
// Get the tracks from the clipboard
Tracks
*
tracks
=
(
Tracks
*
)
clipboard
->
get
(
"tracks"
);
if
(
tracks
==
NULL
)
return
Success
;
// Otherwise increase the event number
eventNumber
++
;
return
Success
;
...
...
branches/trunk/algorithms/GUI.h
View file @
586dd8f2
...
...
@@ -29,7 +29,7 @@ public:
// Plot holders
vector
<
TCanvas
*>
canvases
;
map
<
TCanvas
*
,
vector
<
TH1
*>>
histograms
;
map
<
TCanvas
*
,
vector
<
TH1
*>
>
histograms
;
map
<
TH1
*
,
string
>
styles
;
// Add plots and canvases
...
...
branches/trunk/algorithms/Timepix3EventLoader.C
View file @
586dd8f2
...
...
@@ -112,13 +112,14 @@ StatusCode Timepix3EventLoader::run(Clipboard* clipboard){
// Check if they are a Timepix3
string
detectorID
=
parameters
->
detectors
[
det
];
if
(
parameters
->
detector
[
detectorID
]
->
type
()
!=
"Timepix3"
)
continue
;
if
(
parameters
->
masked
.
count
(
detectorID
))
continue
;
// Make a new container for the data
Pixels
*
deviceData
=
new
Pixels
();
SpidrSignals
*
spidrData
=
new
SpidrSignals
();
// Load the next chunk of data
if
(
debug
)
tcout
<<
"Loading data from "
<<
detectorID
<<
endl
;
//
if(debug) tcout<<"Loading data from "<<detectorID<<endl;
bool
data
=
loadData
(
detectorID
,
deviceData
,
spidrData
);
// If data was loaded then put it on the clipboard
...
...
@@ -266,7 +267,7 @@ bool Timepix3EventLoader::loadData(string detectorID, Pixels* devicedata, SpidrS
m_syncTime
[
detectorID
]
=
(
m_syncTime
[
detectorID
]
&
0x00000FFFFFFFFFFF
)
+
((
pixdata
&
0x00000000FFFF0000
)
<<
28
);
// if(detectorID == "W0019_F07") tcout<<"Updating heartbeat part 2. Now syncTime = "<<(double)m_syncTime[detectorID]/(4096. * 40000000.)<<endl;
// if( m_syncTime[detectorID] < 0x0000010000000000 && !m_clearedHeader[detectorID]) m_clearedHeader[detectorID] = true;
if
(
!
m_clearedHeader
[
detectorID
]
&&
(
double
)
m_syncTime
[
detectorID
]
/
(
4096
.
*
40000000
.)
<
2
.
5
)
m_clearedHeader
[
detectorID
]
=
true
;
if
(
!
m_clearedHeader
[
detectorID
]
&&
(
double
)
m_syncTime
[
detectorID
]
/
(
4096
.
*
40000000
.)
<
6
.
)
m_clearedHeader
[
detectorID
]
=
true
;
}
// if(detectorID == "W0019_F07") tcout<<"Updating heartbeat. Now syncTime = "<<(double)m_syncTime[detectorID]/(4096. * 40000000.)<<endl;
...
...
@@ -384,8 +385,8 @@ bool Timepix3EventLoader::loadData(string detectorID, Pixels* devicedata, SpidrS
// Calculate the timestamp.
long
long
int
time
=
(((
spidrTime
<<
18
)
+
(
toa
<<
4
)
+
(
15
-
ftoa
))
<<
8
)
+
(
m_syncTime
[
detectorID
]
&
0xFFFFFC0000000000
);
if
(
debug
)
tcout
<<
"Pixel time "
<<
(
double
)
time
/
(
4096
.
*
40000000
.)
<<
endl
;
if
(
debug
)
tcout
<<
"Sync time "
<<
(
double
)
m_syncTime
[
detectorID
]
/
(
4096
.
*
40000000
.)
<<
endl
;
//
if(debug) tcout<<"Pixel time "<<(double)time/(4096. * 40000000.)<<endl;
//
if(debug) tcout<<"Sync time "<<(double)m_syncTime[detectorID]/(4096. * 40000000.)<<endl;
// Add the timing offset from the coniditions file (if any)
time
+=
(
long
long
int
)(
parameters
->
detector
[
detectorID
]
->
timingOffset
()
*
4096
.
*
40000000
.);
...
...
@@ -442,7 +443,7 @@ bool Timepix3EventLoader::loadData(string detectorID, Pixels* devicedata, SpidrS
// Now we have data buffered into the temporary storage. We will sort this by time, and then load
// the data from one event onto it.
debug
=
false
;
//
debug = false;
// If no data was loaded, return false
if
(
npixels
==
0
)
return
false
;
...
...
branches/trunk/core/Steering.C
View file @
586dd8f2
...
...
@@ -84,7 +84,8 @@ int main(int argc, char *argv[]) {
// =========================================================================
// General parameters
// parameters->reference = "W0013_G03";
parameters
->
reference
=
"W0013_G03"
;
parameters
->
DUT
=
"W0039_C08"
;
// parameters->DUT = "W0005_E02";
// parameters->DUT = "W0002_J05";
parameters
->
reference
=
"W0013_G03"
;
...
...
@@ -95,9 +96,14 @@ int main(int argc, char *argv[]) {
// parameters->reference = "Mim-osa02";
// parameters->DUT = "CLi-CPix";
//parameters->reference = "Mim-osa02";
//parameters->DUT = "CLi-CPix";
// parameters->DUT = "W0013_J05";
parameters
->
detectorToAlign
=
parameters
->
DUT
;
parameters
->
excludedFromTracking
[
parameters
->
DUT
]
=
true
;
parameters
->
excludedFromTracking
[
"W0005_E02"
]
=
true
;
parameters
->
excludedFromTracking
[
"W0005_F01"
]
=
true
;
parameters
->
excludedFromTracking
[
"W0019_C07"
]
=
true
;
...
...
@@ -105,10 +111,22 @@ int main(int argc, char *argv[]) {
parameters
->
excludedFromTracking
[
"W0019_F07"
]
=
true
;
parameters
->
excludedFromTracking
[
"W0019_L08"
]
=
true
;
parameters
->
excludedFromTracking
[
"W0005_H03"
]
=
true
;
parameters
->
excludedFromTracking
[
"W0013_F09"
]
=
true
;
clicpixAnalysis
->
timepix3Telescope
=
true
;
// spatialTracking->debug = true;
parameters
->
masked
[
"W0039_C08"
]
=
true
;
// parameters->masked["W0013_D04"] = true;
// parameters->masked["W0013_E03"] = true;
// parameters->masked["W0013_G02"] = true;
// parameters->masked["W0013_J05"] = true;
// parameters->masked["W0013_L09"] = true;
// parameters->masked["W0013_F09"] = true;
//tpix3EventLoader->debug = true;
basicTracking
->
minHitsOnTrack
=
7
;
//testAlgorithm->makeCorrelations = true;
//dataDump->m_detector = parameters->DUT;
...
...
@@ -145,7 +163,7 @@ int main(int argc, char *argv[]) {
if
(
parameters
->
align
)
analysis
->
add
(
alignment
);
if
(
parameters
->
produceMask
)
analysis
->
add
(
tpix3MaskCreator
);
if
(
parameters
->
eventDisplay
)
analysis
->
add
(
eventDisplay
);
if
(
parameters
->
gui
)
analysis
->
add
(
gui
);
if
(
parameters
->
gui
)
analysis
->
add
(
onlineMonitor
);
// Run the analysis
analysis
->
run
();
...
...
branches/trunk/macros/analyse.sh
View file @
586dd8f2
...
...
@@ -8,8 +8,8 @@ RUN=${1}
CONDFILE
=
${
TBCODE
}
/cond/Alignment
${
RUN
}
.dat
HISTOFILE
=
${
TBCODE
}
/histos/histogramsRun
${
RUN
}
test.root
INPUTFILE
=
${
TBCODE
}
/pixels/pixelsRun
${
RUN
}
.root
INPUTFOLDER
=
${
TBCODE
}
/example/Run
${
RUN
}
EVENTTIME
=
0.005
INPUTFOLDER
=
/example/Run
${
RUN
}
EVENTTIME
=
0.00
0
5
NEVENTS
=
-1
# If the alignment file for this run does not exist, get it from the DB
...
...
@@ -26,5 +26,5 @@ then
fi
# Launch the testbeam analysis and replace the original alignment file with the new one
${
TBCODE
}
/bin/tbAnalysis
-c
${
CONDFILE
}
-n
${
NEVENTS
}
-h
${
HISTOFILE
}
-t
${
INPUTFILE
}
-s
${
TBCODE
}
/masks/maskedPixels11044.dat
#
${TBCODE}/bin/tbAnalysis -c ${CONDFILE} -h ${HISTOFILE} -d ${INPUTFOLDER} -p ${EVENTTIME}
#
${TBCODE}/bin/tbAnalysis -c ${CONDFILE} -n ${NEVENTS} -h ${HISTOFILE} -t ${INPUTFILE} -s ${TBCODE}/masks/maskedPixels11044.dat
${
TBCODE
}
/bin/tbAnalysis
-c
${
CONDFILE
}
-h
${
HISTOFILE
}
-d
${
INPUTFOLDER
}
-p
${
EVENTTIME
}
-g
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment