61 |
echo "TTree *tc1 = (TTree*)_file0->Get(\"CalibTrk1\")" >> ${TEMPL}; |
echo "TTree *tc1 = (TTree*)_file0->Get(\"CalibTrk1\")" >> ${TEMPL}; |
62 |
echo "TTree *tc2 = (TTree*)_file0->Get(\"CalibTrk2\")" >> ${TEMPL}; |
echo "TTree *tc2 = (TTree*)_file0->Get(\"CalibTrk2\")" >> ${TEMPL}; |
63 |
echo "TTree *s4c = (TTree*)_file0->Get(\"CalibS4\")" >> ${TEMPL}; |
echo "TTree *s4c = (TTree*)_file0->Get(\"CalibS4\")" >> ${TEMPL}; |
64 |
|
echo "TTree *mcmd = (TTree*)_file0->Get(\"Mcmd\")" >> ${TEMPL}; |
65 |
echo "TTree *ccp = 0;" >> ${TEMPL}; |
echo "TTree *ccp = 0;" >> ${TEMPL}; |
66 |
echo "TTree *ccp1 = 0;" >> ${TEMPL}; |
echo "TTree *ccp1 = 0;" >> ${TEMPL}; |
67 |
echo "TTree *ccp2 = 0;" >> ${TEMPL}; |
echo "TTree *ccp2 = 0;" >> ${TEMPL}; |
69 |
echo "TTree *ctc1 = 0;" >> ${TEMPL}; |
echo "TTree *ctc1 = 0;" >> ${TEMPL}; |
70 |
echo "TTree *ctc2 = 0;" >> ${TEMPL}; |
echo "TTree *ctc2 = 0;" >> ${TEMPL}; |
71 |
echo "TTree *cs4c = 0;" >> ${TEMPL}; |
echo "TTree *cs4c = 0;" >> ${TEMPL}; |
72 |
|
echo "TTree *cmcmd = 0;" >> ${TEMPL}; |
73 |
echo "TFile *calib = new TFile(\"${OUTDIR}/${FNAME}/nome\",\"RECREATE\");" >> ${TEMPL}; |
echo "TFile *calib = new TFile(\"${OUTDIR}/${FNAME}/nome\",\"RECREATE\");" >> ${TEMPL}; |
74 |
echo "calib->SetCompressionLevel(9);" >> ${TEMPL}; |
echo "calib->SetCompressionLevel(9);" >> ${TEMPL}; |
75 |
echo "calib->cd();" >> ${TEMPL}; |
echo "calib->cd();" >> ${TEMPL}; |
80 |
echo "ctc1=tc1->CloneTree(-1,\"fast\");" >> ${TEMPL}; |
echo "ctc1=tc1->CloneTree(-1,\"fast\");" >> ${TEMPL}; |
81 |
echo "ctc2=tc2->CloneTree(-1,\"fast\");" >> ${TEMPL}; |
echo "ctc2=tc2->CloneTree(-1,\"fast\");" >> ${TEMPL}; |
82 |
echo "cs4c=s4c->CloneTree(-1,\"fast\");" >> ${TEMPL}; |
echo "cs4c=s4c->CloneTree(-1,\"fast\");" >> ${TEMPL}; |
83 |
|
echo "cmcmd=mcmd->CloneTree(-1,\"fast\");" >> ${TEMPL}; |
84 |
echo "calib->Write();" >> ${TEMPL}; |
echo "calib->Write();" >> ${TEMPL}; |
85 |
echo "calib->Close();" >> ${TEMPL}; |
echo "calib->Close();" >> ${TEMPL}; |
86 |
echo ".q" >> ${TEMPL}; |
echo ".q" >> ${TEMPL}; |
93 |
echo ${FN} >> ${LOG}; |
echo ${FN} >> ${LOG}; |
94 |
CH=`echo $FN |grep .root`; |
CH=`echo $FN |grep .root`; |
95 |
if [ "$CH" != "" ]; then |
if [ "$CH" != "" ]; then |
96 |
|
echo " Processing file $FN"; |
97 |
cat ${TEMPL} | sed s/nome/${FN}/ > ${GO}; |
cat ${TEMPL} | sed s/nome/${FN}/ > ${GO}; |
98 |
root -b -l < ${GO} &> ${LOG}; |
root -b -l < ${GO} &> ${LOG}; |
99 |
fi; |
fi; |
100 |
done |
done |
101 |
|
rm -f ${LOG}; |
102 |
rm -f ${GO}; |
rm -f ${GO}; |
103 |
rm -f ${TEMPL}; |
rm -f ${TEMPL}; |
104 |
cd ${OUTDIR} && tar zcvf ${OUTDIR}/${FNAME}.tar.gz ${FNAME} ; |
cd ${OUTDIR} && tar zcvf ${OUTDIR}/${FNAME}.tar.gz ${FNAME} ; |