-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'development' into iss64-bankFilter
- Loading branch information
Showing
9 changed files
with
387 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
#!/bin/sh | ||
|
||
. `dirname $0`/env.sh | ||
|
||
export CLAS12DIR=`dirname $0`/.. | ||
|
||
#-------------------------------------------------------------- | ||
# Adding supporting COAT jar files | ||
for i in `ls -a $CLAS12DIR/lib/clas/*.jar` | ||
do | ||
#echo "$i" | ||
if [ -z "${JYPATH}" ] ; then | ||
JYPATH="$i" | ||
else | ||
JYPATH=${JYPATH}:"$i" | ||
fi | ||
done | ||
#-------------------------------------------------------------- | ||
# Adding supporting plugins directory | ||
for i in `ls -a $CLAS12DIR/lib/services/*.jar` | ||
do | ||
if [ -z "${JYPATH}" ] ; then | ||
JYPATH="$i" | ||
else | ||
JYPATH=${JYPATH}:"$i" | ||
fi | ||
done | ||
#-------------------------------------------------------------- | ||
# Adding supporting plugins directory | ||
#-------------------------------------------------------------- | ||
# Done loading plugins | ||
#-------------------------------------------------------------- | ||
# Adding supporting plugins directory | ||
for i in `ls -a $CLAS12DIR/lib/utils/*.jar` | ||
do | ||
if [ -z "${JYPATH}" ] ; then | ||
JYPATH="$i" | ||
else | ||
JYPATH=${JYPATH}:"$i" | ||
fi | ||
done | ||
#------------------------------------------------------------- | ||
echo " " | ||
echo " " | ||
echo "*****************************************" | ||
echo "* Running COAT-JAVA JShell Scripts *" | ||
echo "*****************************************" | ||
echo " " | ||
echo " " | ||
jshell --class-path "$JYPATH" "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
73 changes: 73 additions & 0 deletions
73
reconstruction/ec/src/main/java/org/jlab/display/ec/ECRECMonitor.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
/* | ||
* Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license | ||
* Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template | ||
*/ | ||
package org.jlab.display.ec; | ||
|
||
import org.jlab.clas.physics.LorentzVector; | ||
import org.jlab.clas.reco.ReconstructionEngine; | ||
import org.jlab.groot.data.H1F; | ||
import org.jlab.groot.ui.TGCanvas; | ||
import org.jlab.io.base.DataBank; | ||
import org.jlab.io.base.DataEvent; | ||
|
||
/** | ||
* | ||
* @author gavalian | ||
*/ | ||
public class ECRECMonitor extends ReconstructionEngine { | ||
TGCanvas canvas = null; | ||
H1F pion = null; | ||
|
||
public ECRECMonitor(){ | ||
super("ECMon","gavalian","1.0"); | ||
} | ||
|
||
@Override | ||
public boolean processDataEvent(DataEvent event) { | ||
if(event.hasBank("REC::Particle")==true){ | ||
DataBank bank = event.getBank("REC::Particle"); | ||
int index1 = this.index(bank, 22, 0); | ||
int index2 = this.index(bank, 22, 1); | ||
if(index1>0&&index2>0){ | ||
LorentzVector vL_g1 = this.getVector(bank, index1, 0.0); | ||
LorentzVector vL_g2 = this.getVector(bank, index2, 0.0); | ||
if(vL_g1.p()>1.0&&vL_g2.p()>1.0){ | ||
vL_g1.add(vL_g2); | ||
pion.fill(vL_g1.mass()); | ||
} | ||
} | ||
} | ||
return true; | ||
} | ||
|
||
private LorentzVector getVector(DataBank b, int index, double mass){ | ||
LorentzVector v = new LorentzVector(); | ||
v.setPxPyPzM(b.getFloat("px", index), | ||
b.getFloat("py", index), | ||
b.getFloat("pz", index), | ||
mass); | ||
return v; | ||
} | ||
|
||
private int index(DataBank b, int pid, int skip){ | ||
int nrows = b.rows(); | ||
int skipped = 0; | ||
for(int r = 0; r < nrows; r++){ | ||
int id = b.getInt("pid", r); | ||
if(id==pid){ | ||
if(skipped==skip) return r; | ||
skipped++; | ||
} | ||
} | ||
return -1; | ||
} | ||
@Override | ||
public boolean init() { | ||
canvas = new TGCanvas("c","EC Engine Monitoring",500,500); | ||
canvas.getCanvas().initTimer(5000); | ||
pion = new H1F("pion",120,0.005,0.6); | ||
return true; | ||
} | ||
|
||
} |
Binary file added
BIN
+63.3 KB
reconstruction/mc/src/main/java/org/jlab/service/mc/Figs/ClustersInRecParticle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+69.8 KB
reconstruction/mc/src/main/java/org/jlab/service/mc/Figs/ExampleStatWord.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+21.5 KB
reconstruction/mc/src/main/java/org/jlab/service/mc/Figs/HitsInCluster.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+81.8 KB
reconstruction/mc/src/main/java/org/jlab/service/mc/Figs/Layer_Bits.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.