Skip to content

Commit

Permalink
Split TravisCI jobs to run 1 sim and 1 reco per job. Currently 4 jobs…
Browse files Browse the repository at this point in the history
… will run for l5/s5 and o1/o2 models
  • Loading branch information
rete committed Apr 18, 2018
1 parent 97950ee commit a3ad9e1
Show file tree
Hide file tree
Showing 3 changed files with 73 additions and 82 deletions.
132 changes: 61 additions & 71 deletions .travis-ci.d/test.sh
Expand Up @@ -6,83 +6,73 @@ source $ILCSOFT/init_ilcsoft.sh
cd /Package/StandardConfig/production

##
## Test DDSim for our current detector models
## Test DDSim
##
for detector in ILD_l5_v02 ILD_s5_v02
do
echo "-- Running DDSim ${detector} ..."
ddsim \
--inputFiles Examples/bbudsc_3evt/bbudsc_3evt.stdhep \
--outputFile bbudsc_3evt_SIM_test_${detector}.slcio \
--compactFile $lcgeo_DIR/ILD/compact/${detector}/${detector}.xml \
--steeringFile ddsim_steer.py > travis-ci.log 2>&1
echo "-- Running DDSim ${SIM_MODEL} ..."
ddsim \
--inputFiles Examples/bbudsc_3evt/bbudsc_3evt.stdhep \
--outputFile bbudsc_3evt_SIM_test_${SIM_MODEL}.slcio \
--compactFile $lcgeo_DIR/ILD/compact/${SIM_MODEL}/${SIM_MODEL}.xml \
--steeringFile ddsim_steer.py > travis-ci.log 2>&1

ddsimStatus=$?
ddsimStatus=$?

if [[ $ddsimStatus != 0 ]]
then
cat travis-ci.log
echo "-- ERROR - DDSim ${detector}: 3 events test failed"
exit $ddsimStatus
else
echo "-- DDSim ${detector}: test passing !"
fi

# test presence of output file
if [ ! -f "bbudsc_3evt_SIM_test_${detector}.slcio" ]
then
ls -lthr
echo "-- ERROR - DDSim ${detector}: No output file found (bbudsc_3evt_SIM_test_${detector}.slcio)"
exit 1
fi
done
if [[ $ddsimStatus != 0 ]]
then
cat travis-ci.log
echo "-- ERROR - DDSim ${SIM_MODEL}: 3 events test failed"
exit $ddsimStatus
else
echo "-- DDSim ${SIM_MODEL}: test passing !"
fi

# test presence of output file
if [ ! -f "bbudsc_3evt_SIM_test_${SIM_MODEL}.slcio" ]
then
ls -lthr
echo "-- ERROR - DDSim ${SIM_MODEL}: No output file found (bbudsc_3evt_SIM_test_${SIM_MODEL}.slcio)"
exit 1
fi


##
## Test Marlin reconstruction for our current detector models
## Test Marlin reconstruction
##
for largeOrSmall in l5 s5
do
for detectorOption in o1 o2
do
simDetector="ILD_${largeOrSmall}_v02"
recDetector="ILD_${largeOrSmall}_${detectorOption}_v02"
outputBaseName="bbudsc_3evt_RECNoBG_Test_${recDetector}"

echo "-- Running Marlin ${recDetector} no bg ..."
Marlin MarlinStdReco.xml \
--constant.lcgeo_DIR=$lcgeo_DIR \
--constant.DetectorModel=${recDetector} \
--constant.OutputBaseName=${outputBaseName} \
--constant.RunBeamCalReco=false \
--global.LCIOInputFiles=bbudsc_3evt_SIM_test_${simDetector}.slcio > travis-ci.log 2>&1

marlinStatus=$?
outputBaseName="bbudsc_3evt_RECNoBG_Test_${REC_MODEL}"

if [[ $marlinStatus != 0 ]]
then
cat travis-ci.log
echo "-- ERROR - Marlin ${recDetector} no bg: 3 events test failed"
exit $marlinStatus
else
echo "-- Marlin ${recDetector} no bg: test passing !"
fi

# test presence of different output files
checkFileList="${outputBaseName}_REC.slcio \
${outputBaseName}_DST.slcio \
${outputBaseName}_PfoAnalysis.root \
${outputBaseName}_AIDA.root"
for checkFile in ${checkFileList}
do
if [ ! -f ${checkFile} ]
then
ls -lthr
echo "-- ERROR - Marlin ${recDetector} no bg: Missing output file ${checkFile}"
exit 1
else
echo "-- Marlin ${recDetector} no bg: ${checkFile} present ..."
fi
done
done
echo "-- Running Marlin ${REC_MODEL} no bg ..."
Marlin MarlinStdReco.xml \
--constant.lcgeo_DIR=$lcgeo_DIR \
--constant.DetectorModel=${REC_MODEL} \
--constant.OutputBaseName=${outputBaseName} \
--constant.RunBeamCalReco=false \
--global.LCIOInputFiles=bbudsc_3evt_SIM_test_${SIM_MODEL}.slcio > travis-ci.log 2>&1

marlinStatus=$?

if [[ $marlinStatus != 0 ]]
then
cat travis-ci.log
echo "-- ERROR - Marlin ${REC_MODEL} no bg: 3 events test failed"
exit $marlinStatus
else
echo "-- Marlin ${REC_MODEL} no bg: test passing !"
fi

# test presence of different output files
checkFileList="${outputBaseName}_REC.slcio \
${outputBaseName}_DST.slcio \
${outputBaseName}_PfoAnalysis.root \
${outputBaseName}_AIDA.root"
for checkFile in ${checkFileList}
do
if [ ! -f ${checkFile} ]
then
ls -lthr
echo "-- ERROR - Marlin ${REC_MODEL} no bg: Missing output file ${checkFile}"
exit 1
else
echo "-- Marlin ${REC_MODEL} no bg: ${checkFile} present ..."
fi
done

9 changes: 8 additions & 1 deletion .travis.yml
@@ -1,6 +1,13 @@
sudo: required
dist: trusty

env:
matrix:
- SIM_MODEL=ILD_l5_v02 REC_MODEL=ILD_l5_o1_v02
- SIM_MODEL=ILD_s5_v02 REC_MODEL=ILD_s5_o1_v02
- SIM_MODEL=ILD_l5_v02 REC_MODEL=ILD_l5_o2_v02
- SIM_MODEL=ILD_s5_v02 REC_MODEL=ILD_s5_o2_v02

services:
- docker

Expand Down Expand Up @@ -31,7 +38,7 @@ install:

# command to run tests
script:
- docker run -it --name CI_container -v $PKGDIR:/Package -v /cvmfs/clicdp.cern.ch:/cvmfs/clicdp.cern.ch -d clicdp/slc6-build /bin/bash
- docker run -it --name CI_container -e SIM_MODEL=$SIM_MODEL -e REC_MODEL=$REC_MODEL -v $PKGDIR:/Package -v /cvmfs/clicdp.cern.ch:/cvmfs/clicdp.cern.ch -d clicdp/slc6-build /bin/bash
- docker exec -it CI_container /bin/bash -c "./Package/.travis-ci.d/test.sh";

# Don't send e-mail notifications
Expand Down
14 changes: 4 additions & 10 deletions StandardConfig/production/HighLevelReco/HighLevelReco.xml
Expand Up @@ -142,7 +142,7 @@
<processor name="MyRecoMCTruthLinker" type="RecoMCTruthLinker">
<!--links RecontructedParticles to the MCParticle based on number of hits used-->
<!--verbosity level of this processor ("DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT")-->
<parameter name="Verbosity" options="DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT"> WARNING0 </parameter>
<!-- <parameter name="Verbosity" options="DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT"> WARNING0 </parameter> -->
<!-- Input collections: mcparticles, pfos, clusters and tracks
PFOs already connect to tracks and clusters, so what we do in this processor is to connect
tracks and clusters to mcparticles ...
Expand Down Expand Up @@ -231,6 +231,8 @@
<parameter name="UseTrackerHitRelations" type="bool"> true </parameter>
<!--If Using Particle Gun Ignore Gen Stat-->
<parameter name="UsingParticleGun" type="bool"> false </parameter>
<!--verbosity level of this processor ("DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT")-->
<parameter name="Verbosity" type="string">MESSAGE </parameter>
</processor>


Expand Down Expand Up @@ -290,8 +292,6 @@
<parameter name="ReconstructedParticleCollection" type="string" lcioInType="ReconstructedParticle">PandoraPFOs </parameter>
<!--Assumed time resolution per hit in ps-->
<parameter name="TimeResolution" type="float">0 </parameter>
<!--verbosity level of this processor ("DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT")-->
<!--parameter name="Verbosity" type="string">DEBUG </parameter-->
</processor>
<processor name="TOFEstimators10ps" type="TOFEstimators">
<!--TOFEstimators compute some estimators for the time of flight from calorimeter hits-->
Expand All @@ -301,8 +301,6 @@
<parameter name="ReconstructedParticleCollection" type="string" lcioInType="ReconstructedParticle">PandoraPFOs </parameter>
<!--Assumed time resolution per hit in ps-->
<parameter name="TimeResolution" type="float">10. </parameter>
<!--verbosity level of this processor ("DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT")-->
<!--parameter name="Verbosity" type="string">DEBUG </parameter-->
</processor>
<processor name="TOFEstimators50ps" type="TOFEstimators">
<!--TOFEstimators compute some estimators for the time of flight from calorimeter hits-->
Expand All @@ -312,11 +310,7 @@
<parameter name="ReconstructedParticleCollection" type="string" lcioInType="ReconstructedParticle">PandoraPFOs </parameter>
<!--Assumed time resolution per hit in ps-->
<parameter name="TimeResolution" type="float">50 </parameter>
<!--verbosity level of this processor ("DEBUG0-4,MESSAGE0-4,WARNING0-4,ERROR0-4,SILENT")-->
<!--parameter name="Verbosity" type="string">DEBUG </parameter-->
</processor>




</group>

0 comments on commit a3ad9e1

Please sign in to comment.