Commit in hps-java/src/main/java/org/lcsim/hps/recon/ecal on MAIN | |||
EcalCrystalFilter.java | +109 | -64 | 1.3 -> 1.4 |
Fixed display of the individual crystals
diff -u -r1.3 -r1.4 --- EcalCrystalFilter.java 8 Jun 2012 16:43:07 -0000 1.3 +++ EcalCrystalFilter.java 8 Jun 2012 17:45:50 -0000 1.4 @@ -89,10 +89,16 @@
private JComboBox xComboTop; private JComboBox yComboTop; private JButton blankButtonTop;
+ private JLabel xLabelBot, yLabelBot; + private JComboBox xComboBot; + private JComboBox yComboBot; + private JButton blankButtonBot;
private static final Integer[] xList = new Integer[46]; private static final Integer[] yList = new Integer[10]; private static final Integer[] xListTop = new Integer[46]; private static final Integer[] yListTop = new Integer[10];
+ private static final Integer[] xListBot = new Integer[46]; + private static final Integer[] yListBot = new Integer[10];
int eventRefreshRate = 1; int eventn = 0; boolean hide = false;
@@ -110,6 +116,8 @@
if (i != 0) { xList[count] = i; xListTop[count] = i;
+ xListBot[count] = i; +
count++; } }
@@ -118,6 +126,7 @@
if (i != 0) { yList[count] = i; yListTop[count] = i;
+ yListBot[count] = i;
count++; } }
@@ -164,15 +173,15 @@
tSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Time) Filter", 50,0,50); tMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Time) Filter", 50, 0, 100);
- aTSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Amplitude) Top Filter", 50, 0,200); - aTMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Amplitude) Top Filter", 50, 0,1000); - tTSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Time) Top Filter", 50,0,50); - tTMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Time) Top Filter", 50, 0, 100); - - aBSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Amplitude) Bottom Filter", 50, 0,200); - aBMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Amplitude) Bottom Filter", 50, 0,1000); - tBSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Time) Bottom Filter", 50,0,50); - tBMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Time) Bottom Filter", 50, 0, 100);
+ aTSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Amplitude) Top Trig Filter", 50, 0,200); + aTMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Amplitude) Top Trig Filter", 50, 0,1000); + tTSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Time) Top Trig Filter", 50,0,50); + tTMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Time) Top Trig Filter", 50, 0, 100); + + aBSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Amplitude) Bottom Trig Filter", 50, 0,200); + aBMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Amplitude) Bottom Trig Filter", 50, 0,1000); + tBSigmaPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Sigma> (Time) Bottom Trig Filter", 50,0,50); + tBMeanPlot = aida.histogram1D(detector.getDetectorName() + " : " + inputCollection + " : <Mean> (Time) Bottom Trig Filter", 50, 0, 100);
aTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Amplitude) Time Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5);
@@ -180,15 +189,15 @@
tTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Time) Time Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); tTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Time) Time Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5);
- aTTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Amplitude) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); - aTTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Amplitude) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); - tTTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Time) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); - tTTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Time) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); - - aBTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Amplitude) Time Bottom Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); - aBTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Amplitude) Time Bottom Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); - tBTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Time) Time Bottom Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); - tBTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Time) Time Bottom Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5);
+ aTTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Amplitude) Time Bot Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); + aTTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Amplitude) Time Bot Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); + tTTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Time) Time Bot Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); + tTTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Time) Time Bot Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); + + aBTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Amplitude) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); + aBTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Amplitude) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); + tBTOutSigmaPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Sigma (Time) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5); + tBTOutMeanPlot = aida.histogram2D(detector.getDetectorName() + " : " + inputCollection + " : Mean (Time) Time Top Outliers", 47, -23.5, 23.5, 11, -5.5, 5.5);
for (int x = -23; x <= 23; x++) { // slot
@@ -203,12 +212,12 @@
} else { aPlots[x + 23][y + 5] = aida.histogram1D("ECAL Amplitudes: x=" + x + "; y=" + y, 1024, -0.5, 1023.5);
- aTPlots[x + 23][y + 5] = aida.histogram1D("Top CAL Amplitudes: x=" + x + "; y=" + y, 1024, -0.5, 1023.5); - aBPlots[x + 23][y + 5] = aida.histogram1D("Bottom CAL Amplitudes: x=" + x + "; y=" + y, 1024, -0.5, 1023.5);
+ aTPlots[x + 23][y + 5] = aida.histogram1D("Top Trig CAL Amplitudes: x=" + x + "; y=" + y, 1024, -0.5, 1023.5); + aBPlots[x + 23][y + 5] = aida.histogram1D("Bottom Trig CAL Amplitudes: x=" + x + "; y=" + y, 1024, -0.5, 1023.5);
} tPlots[x + 23][y + 5] = aida.histogram1D("ECAL Times: x=" + x + "; y=" + y, 100, 0, 100);
- tTPlots[x + 23][y + 5] = aida.histogram1D("Top ECAL Times: x=" + x + "; y=" + y, 100, 0, 100); - tBPlots[x + 23][y + 5] = aida.histogram1D("Bottom ECAL Times: x=" + x + "; y=" + y, 100, 0, 100);
+ tTPlots[x + 23][y + 5] = aida.histogram1D("Top Trig ECAL Times: x=" + x + "; y=" + y, 100, 0, 100); + tBPlots[x + 23][y + 5] = aida.histogram1D("Bottom Trig ECAL Times: x=" + x + "; y=" + y, 100, 0, 100);
} }
@@ -312,21 +321,16 @@
plotter2.region(2).plot(tPlots[-5 + 23][2 + 5 - 1]); plotter3.region(2).plot(tPlots[-5 + 23][2 + 5 - 1]); plotter4.region(2).plot(aPlots[-5 + 23][2 + 5 - 1]);
- xCombo.setSelectedIndex(-5 + 23); - yCombo.setSelectedIndex(2 + 5 - 1);
- plotterFrame.pack(); - if (!hide) { - plotterFrame.setVisible(true); - }
+
plotterFrameTop = new AIDAFrame();
- plotterFrameTop.setTitle("HPS Top ECal Crystal Filter Plots");
+ plotterFrameTop.setTitle("HPS Top Trig ECal Crystal Filter Plots");
xComboTop = new JComboBox(xListTop); xComboTop.addActionListener(this);
@@ -338,12 +342,15 @@
yComboTop.addActionListener(this); yLabelTop = new JLabel("yT"); yLabelTop.setLabelFor(yComboTop);
+ +
plotterFrameTop.getControlsPanel().add(yLabelTop); plotterFrameTop.getControlsPanel().add(yComboTop); blankButtonTop = new JButton("Hide histogram (Top)"); plotterFrameTop.getControlsPanel().add(blankButtonTop); blankButtonTop.addActionListener(this);
-
+ +
// Setup the plotterTop. plotterTop = aida.analysisFactory().createPlotterFactory().create(); plotterTop.setTitle("HPS ECal Amplitude");
@@ -413,17 +420,6 @@
plotterTop2.region(2).plot(tTPlots[-5 + 23][2 + 5 - 1]); plotterTop3.region(2).plot(tTPlots[-5 + 23][2 + 5 - 1]); plotterTop4.region(2).plot(aTPlots[-5 + 23][2 + 5 - 1]);
- xComboTop.setSelectedIndex(-5 + 23); - yComboTop.setSelectedIndex(2 + 5 - 1); - - - - plotterFrameTop.pack(); - if (!hide) { - plotterFrameTop.setVisible(true); - } - -
@@ -433,23 +429,23 @@
plotterFrameBot = new AIDAFrame();
- plotterFrameBot.setTitle("HPS Bottom ECal Crystal Filter Plots");
+ plotterFrameBot.setTitle("HPS Bottom Trig ECal Crystal Filter Plots");
- //xCombo = new JComboBox(xList); - //xCombo.addActionListener(this); - //xLabel = new JLabel("x"); - //xLabel.setLabelFor(xCombo); - //plotterFrameBot.getControlsPanel().add(xLabel); - //plotterFrameBot.getControlsPanel().add(xCombo); - //yCombo = new JComboBox(yList); - //yCombo.addActionListener(this); - //yLabel = new JLabel("y"); - //yLabel.setLabelFor(yCombo); - //plotterFrameBot.getControlsPanel().add(yLabel); - //plotterFrameBot.getControlsPanel().add(yCombo); - //blankButton = new JButton("Hide histogram"); - //plotterFrameBot.getControlsPanel().add(blankButton); - //blankButton.addActionListener(this);
+ xComboBot = new JComboBox(xListBot); + xComboBot.addActionListener(this); + xLabelBot = new JLabel("x"); + xLabelBot.setLabelFor(xComboBot); + plotterFrameBot.getControlsPanel().add(xLabelBot); + plotterFrameBot.getControlsPanel().add(xComboBot); + yComboBot = new JComboBox(yListBot); + yComboBot.addActionListener(this); + yLabelBot = new JLabel("y"); + yLabelBot.setLabelFor(yComboBot); + plotterFrameBot.getControlsPanel().add(yLabelBot); + plotterFrameBot.getControlsPanel().add(yComboBot); + blankButtonBot = new JButton("Hide histogram"); + plotterFrameBot.getControlsPanel().add(blankButtonBot); + blankButtonBot.addActionListener(this);
// Setup the plotterBot. plotterBot = aida.analysisFactory().createPlotterFactory().create();
@@ -525,15 +521,46 @@
+ + + plotterFrame.pack(); + if (!hide) { + plotterFrame.setVisible(true); + } + + + + plotterFrameTop.pack(); + if (!hide) { + plotterFrameTop.setVisible(true); + } + + + +
plotterFrameBot.pack(); if (!hide) { plotterFrameBot.setVisible(true); }
+ + xComboBot.setSelectedIndex(-5 + 23); + yComboBot.setSelectedIndex(2 + 5 - 1); + + + + xComboTop.setSelectedIndex(-5 + 23); + yComboTop.setSelectedIndex(2 + 5 - 1); +
+ xCombo.setSelectedIndex(-5 + 23); + yCombo.setSelectedIndex(2 + 5 - 1); + + +
}
@@ -821,6 +848,14 @@
*/
+ } else if(ae.getSource() == blankButtonTop) { + plotterTop.region(2).clear(); + plotterTop2.region(2).clear(); + + } else if(ae.getSource() == blankButtonBot) { + plotterBot.region(2).clear(); + plotterBot2.region(2).clear(); +
} else { Integer x, y; x = (Integer) xCombo.getSelectedItem();
@@ -835,14 +870,9 @@
plotter3.region(2).plot(tPlots[x + 23][y + 5]); plotter4.region(2).clear(); plotter4.region(2).plot(aPlots[x + 23][y + 5]);
- } - - if(ae.getSource() == blankButtonTop) { - plotterTop.region(2).clear(); - plotterTop2.region(2).clear();
+
- } else { - Integer x, y;
+ //Integer x, y;
x = (Integer) xComboTop.getSelectedItem(); y = (Integer) yComboTop.getSelectedItem();
@@ -856,6 +886,21 @@
plotterTop3.region(2).plot(tTPlots[x + 23][y + 5]); plotterTop4.region(2).clear(); plotterTop4.region(2).plot(aTPlots[x + 23][y + 5]);
+ + //Integer x, y; + x = (Integer) xComboBot.getSelectedItem(); + y = (Integer) yComboBot.getSelectedItem(); + + plotterBot.region(2).clear(); + plotterBot.region(2).plot(aBPlots[x + 23][y + 5]); + plotterBot2.region(2).clear(); + plotterBot2.region(2).plot(tBPlots[x + 23][y + 5]); +// ((PlotterRegion) plotter.region(2)).getPlot().setAllowUserInteraction(false); +// ((PlotterRegion) plotter.region(2)).getPlot().setAllowPopupMenus(false); + plotterBot3.region(2).clear(); + plotterBot3.region(2).plot(tBPlots[x + 23][y + 5]); + plotterBot4.region(2).clear(); + plotterBot4.region(2).plot(aBPlots[x + 23][y + 5]);
} }
Use REPLY-ALL to reply to list
To unsubscribe from the LCD-CVS list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=LCD-CVS&A=1