From 4cc6f8937e350efb01d3edeb203dffb589ab997f Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 10:21:05 -0600 Subject: [PATCH 01/13] Fix typo in QGL variable --- TopTagger/src/TopTaggerUtilities.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TopTagger/src/TopTaggerUtilities.cpp b/TopTagger/src/TopTaggerUtilities.cpp index cfc9364c..962d321d 100644 --- a/TopTagger/src/TopTaggerUtilities.cpp +++ b/TopTagger/src/TopTaggerUtilities.cpp @@ -446,7 +446,7 @@ namespace ttUtility { if(j_m_lab_[i] >= 0) *(basePtr_ + j_m_lab_[i] + len_*iCand) = top_constituents[i]->p().M(); if(j_CSV_lab_[i] >= 0) *(basePtr_ + j_CSV_lab_[i] + len_*iCand) = top_constituents[i]->getBTagDisc(); - if(j_QGL_[i] >= 0) *(basePtr_ + j_QGL_lab_[i] + len_*iCand) = relu(top_constituents[i]->getExtraVar("qgLikelihood")); + if(j_QGL_lab_[i] >= 0) *(basePtr_ + j_QGL_lab_[i] + len_*iCand) = relu(top_constituents[i]->getExtraVar("qgLikelihood")); if(j_qgPtD_lab_[i] >= 0) *(basePtr_ + j_qgPtD_lab_[i] + len_*iCand) = relu(top_constituents[i]->getExtraVar("qgPtD")); if(j_qgAxis1_lab_[i] >= 0) *(basePtr_ + j_qgAxis1_lab_[i] + len_*iCand) = relu(top_constituents[i]->getExtraVar("qgAxis1")); if(j_qgAxis2_lab_[i] >= 0) *(basePtr_ + j_qgAxis2_lab_[i] + len_*iCand) = relu(top_constituents[i]->getExtraVar("qgAxis2")); From 5de89c0fd3775a29b9561c55c3179ddb30ba4db6 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 10:21:47 -0600 Subject: [PATCH 02/13] Make gen matching function more general --- TopTagger/interface/TopTaggerUtilities.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/TopTagger/interface/TopTaggerUtilities.h b/TopTagger/interface/TopTaggerUtilities.h index 76d4bddb..5519208e 100644 --- a/TopTagger/interface/TopTaggerUtilities.h +++ b/TopTagger/interface/TopTaggerUtilities.h @@ -719,14 +719,14 @@ namespace ttUtility } template, typename INTCONTAINERTYPE = std::vector > - std::pair, std::vector>> GetTopdauGenLVecFromNano(const TLVCONTAINERTYPE& genDecayLVec, const INTCONTAINERTYPE& genDecayPdgIdVec, const INTCONTAINERTYPE& genDecayStatFlag, const INTCONTAINERTYPE& genDecayMomIdxVec) + std::pair, std::vector>> GetTopdauGenLVecFromNano(const TLVCONTAINERTYPE& genDecayLVec, const INTCONTAINERTYPE& genDecayPdgIdVec, const INTCONTAINERTYPE& genDecayStatFlag, const INTCONTAINERTYPE& genDecayMomIdxVec, const int targedId = 6, const unsigned int targetDaughters = 3) { std::pair, std::vector>> returnVal; for(unsigned iTop=0; iTop < genDecayLVec.size(); ++iTop) { int pdgId = genDecayPdgIdVec[iTop]; int statFlag = genDecayStatFlag[iTop]; //statFlag bits 0x2100 mean last copy and from hard process - if(abs(pdgId) == 6 && ((statFlag & 0x2100) == 0x2100)) + if(abs(pdgId) == targedId && ((statFlag & 0x2100) == 0x2100)) { //This is a top //Search for daughters of this gen particle @@ -746,7 +746,7 @@ namespace ttUtility } } - if(daughters.size() >= 3) + if(daughters.size() >= targetDaughters) { //hadronic top found returnVal.first.push_back(genDecayLVec[iTop]); From 335d95e10387e97576ff2d21ba3e6e26e183063d Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 10:23:19 -0600 Subject: [PATCH 03/13] Update module so RF tagger can be run with updated framework --- TopTagger/interface/TTMOpenCVMVA.h | 10 +++++++ TopTagger/src/TTMOpenCVMVA.cpp | 45 +++++++++++++++++++----------- 2 files changed, 38 insertions(+), 17 deletions(-) diff --git a/TopTagger/interface/TTMOpenCVMVA.h b/TopTagger/interface/TTMOpenCVMVA.h index 8b19bcd6..2054c98d 100644 --- a/TopTagger/interface/TTMOpenCVMVA.h +++ b/TopTagger/interface/TTMOpenCVMVA.h @@ -5,12 +5,18 @@ #include #include +#include #ifdef SHOTTOPTAGGER_DO_OPENCV #include "opencv/cv.h" #include "opencv/ml.h" #endif +namespace ttUtility +{ + class MVAInputCalculator; +} + /** *This module implements an interface to the OpenCV randomforest package for filtering top candidates. This module can either pass entries directly into the final top list, or filter entries out of the final top list if they do not pass the selection criteria. * @@ -34,6 +40,10 @@ class TTMOpenCVMVA : public TTModule cv::Ptr treePtr_; std::vector vars_; + //variable calclator + std::unique_ptr varCalculator_; + std::vector values_; + #endif public: diff --git a/TopTagger/src/TTMOpenCVMVA.cpp b/TopTagger/src/TTMOpenCVMVA.cpp index 572423e9..e4970ec7 100644 --- a/TopTagger/src/TTMOpenCVMVA.cpp +++ b/TopTagger/src/TTMOpenCVMVA.cpp @@ -63,6 +63,14 @@ void TTMOpenCVMVA::getParameters(const cfg::CfgDocument* cfgDoc, const std::stri { THROW_TTEXCEPTION("Incorrect number of variables specified!!! " + std::to_string(treePtr_->getVarCount()) + "expected " + std::to_string(vars_.size()) + " found."); } + + //load variables + varCalculator_.reset(new ttUtility::TrijetInputCalculator()); + //map variables + varCalculator_->mapVars(vars_); + values_.resize(vars_.size()); + varCalculator_->setPtr(values_.data()); + #else //Mark variables unused to suppress warnings (void)cfgDoc; @@ -86,28 +94,31 @@ void TTMOpenCVMVA::run(TopTaggerResults& ttResults) { //Prepare data from top candidate (this code is shared with training tuple producer) //Perhaps one day the intermediate map can be bypassed ... - std::map varMap = ttUtility::createMVAInputs(topCand, csvThreshold_); +// std::map varMap = ttUtility::createMVAInputs(topCand, csvThreshold_); //Construct opencv data matrix for prediction cv::Mat inputData(vars_.size(), 1, 5); //the last 5 is for CV_32F var type - //populate opencv data matrix based on desired input variables - for(unsigned int i = 0; i < vars_.size(); ++i) - { - inputData.at(i, 0) = varMap[vars_[i]]; - } - - //predict value - double discriminator = treePtr_->predict(inputData); - topCand.setDiscriminator(discriminator); - - //Check number of b-tagged jets in the top - bool passBrequirements = maxNbInTop_ < 0 || topCand.getNBConstituents(csvThreshold_, bEtaCut_) <= maxNbInTop_; - - //place in final top list if it passes the threshold - if(discriminator > discriminator_ && passBrequirements) + if(varCalculator_->calculateVars(topCand, 0)) { - tops.push_back(&topCand); + //populate opencv data matrix based on desired input variables + for(unsigned int i = 0; i < values_.size(); ++i) + { + inputData.at(i, 0) = values_[i]; + } + + //predict value + double discriminator = treePtr_->predict(inputData); + topCand.setDiscriminator(discriminator); + + //Check number of b-tagged jets in the top + bool passBrequirements = maxNbInTop_ < 0 || topCand.getNBConstituents(csvThreshold_, bEtaCut_) <= maxNbInTop_; + + //place in final top list if it passes the threshold + if(discriminator > discriminator_ && passBrequirements) + { + tops.push_back(&topCand); + } } } } From 7297f48de9765fa93844e2df65c7b4710f8bf8cc Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 10:23:55 -0600 Subject: [PATCH 04/13] Remove limited precision from nanoAOD variables saved to remove issues with rounding --- TopTagger/python/TopTaggerProducer.py | 36 ++++++++++++++------------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/TopTagger/python/TopTaggerProducer.py b/TopTagger/python/TopTaggerProducer.py index 672934b4..6cbc78c6 100644 --- a/TopTagger/python/TopTaggerProducer.py +++ b/TopTagger/python/TopTaggerProducer.py @@ -41,6 +41,8 @@ def __init__(self, cfgName="TopTagger.cfg", cfgWD=".", suffix=None, saveAK8=Fals if self.saveCandidates: self.suffixResolved = "Candidate" + self.suffix + else: + self.suffixResolved = self.suffix def beginJob(self): pass @@ -51,33 +53,33 @@ def endJob(self): def beginFile(self, inputFile, outputFile, inputTree, wrappedOutputTree): self.isFirstEventOfFile = True self.out = wrappedOutputTree - self.out.branch("ResolvedTop%s_pt"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved, limitedPrecision=12) - self.out.branch("ResolvedTop%s_eta"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved, limitedPrecision=12) - self.out.branch("ResolvedTop%s_phi"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved, limitedPrecision=12) - self.out.branch("ResolvedTop%s_mass"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved, limitedPrecision=12) - self.out.branch("ResolvedTop%s_discriminator"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved, limitedPrecision=12) + self.out.branch("ResolvedTop%s_pt"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved) + self.out.branch("ResolvedTop%s_eta"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved) + self.out.branch("ResolvedTop%s_phi"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved) + self.out.branch("ResolvedTop%s_mass"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved) + self.out.branch("ResolvedTop%s_discriminator"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved) self.out.branch("ResolvedTop%s_j1Idx"%self.suffixResolved, "I", lenVar="nResolvedTop%s"%self.suffixResolved) self.out.branch("ResolvedTop%s_j2Idx"%self.suffixResolved, "I", lenVar="nResolvedTop%s"%self.suffixResolved) self.out.branch("ResolvedTop%s_j3Idx"%self.suffixResolved, "I", lenVar="nResolvedTop%s"%self.suffixResolved) self.out.branch("ResolvedTop%s_genMatch"%self.suffixResolved, "O", lenVar="nResolvedTop%s"%self.suffixResolved) if self.saveSFAndSyst: - self.out.branch("ResolvedTop%s_sf"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved, limitedPrecision=12) + self.out.branch("ResolvedTop%s_sf"%self.suffixResolved, "F", lenVar="nResolvedTop%s"%self.suffixResolved) for syst in self.systToSave: - self.out.branch("ResolvedTop%s_syst_%s"%(self.suffixResolved, syst), "F", lenVar="nResolvedTop%s"%self.suffixResolved, limitedPrecision=12) + self.out.branch("ResolvedTop%s_syst_%s"%(self.suffixResolved, syst), "F", lenVar="nResolvedTop%s"%self.suffixResolved) if self.saveAK8: - self.out.branch("MergedTop%s_pt"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedTop%s_eta"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedTop%s_phi"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedTop%s_mass"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedTop%s_discriminator"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix, limitedPrecision=12) + self.out.branch("MergedTop%s_pt"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix) + self.out.branch("MergedTop%s_eta"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix) + self.out.branch("MergedTop%s_phi"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix) + self.out.branch("MergedTop%s_mass"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix) + self.out.branch("MergedTop%s_discriminator"%self.suffix, "F", lenVar="nMergedTop%s"%self.suffix) - self.out.branch("MergedW%s_pt"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedW%s_eta"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedW%s_phi"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedW%s_mass"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix, limitedPrecision=12) - self.out.branch("MergedW%s_discriminator"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix, limitedPrecision=12) + self.out.branch("MergedW%s_pt"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix) + self.out.branch("MergedW%s_eta"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix) + self.out.branch("MergedW%s_phi"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix) + self.out.branch("MergedW%s_mass"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix) + self.out.branch("MergedW%s_discriminator"%self.suffix, "F", lenVar="nMergedW%s"%self.suffix) def endFile(self, inputFile, outputFile, inputTree, wrappedOutputTree): From 6c8c7b00df7f84482619343213e67ad65bd7f763 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 10:34:35 -0600 Subject: [PATCH 05/13] Update docker container --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index d3f99c2c..ab6f2693 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,7 @@ language: cpp env: global: - - DOCKER_CONTAINER: cmssw/slc6-base:latest + - DOCKER_CONTAINER: cmssw/slc6:latest - GH_REPO_NAME: TopTagger - GH_ORG_NAME: susy2015 - DOXYFILE: $TRAVIS_BUILD_DIR/.Doxyfile From f2c0b0dc3c1dbac5141254ceddc337537e850c02 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 11:05:13 -0600 Subject: [PATCH 06/13] Update docker container again --- .travis.yml | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/.travis.yml b/.travis.yml index ab6f2693..04975bc6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,7 @@ language: cpp env: global: - - DOCKER_CONTAINER: cmssw/slc6:latest + - DOCKER_CONTAINER: aperloff/cms-cvmfs-docker:latest - GH_REPO_NAME: TopTagger - GH_ORG_NAME: susy2015 - DOXYFILE: $TRAVIS_BUILD_DIR/.Doxyfile @@ -16,18 +16,6 @@ branches: - /.*/ before_install: -- sudo apt-get -qq update -- sudo apt-get install -qq autofs attr gdb git uuid-dev uuid fuse -- wget --no-check-certificate https://ecsft.cern.ch/dist/cvmfs/cvmfs-release/cvmfs-release-latest_all.deb -- sudo dpkg -i cvmfs-release-latest_all.deb -- sudo apt-get update -- sudo apt-get install -qq cvmfs cvmfs-config-default -- sudo cvmfs_config setup -- sudo echo "CVMFS_HTTP_PROXY=\"DIRECT\"" | sudo tee /etc/cvmfs/default.local > /dev/null -- sudo echo CVMFS_REPOSITORIES=cms.cern.ch | sudo tee -a /etc/cvmfs/default.local > /dev/null -- sudo service autofs restart -- cvmfs_config probe -- sudo cvmfs_config chksetup - sudo docker pull $DOCKER_CONTAINER compiler: @@ -35,7 +23,7 @@ compiler: script: - chmod +x $TRAVIS_BUILD_DIR/.travis/runTests.sh -- sudo docker run -v /cvmfs:/cvmfs -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR +- sudo docker run -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: - if [ "$TRAVIS_BRANCH" = "$TARGET_BRANCH" ] || [ ! -z $TRAVIS_TAG ]; then if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sudo apt-get install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz; fi; fi From 069d6781cbeb5014829fea20ab8ab1233bff6be8 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 17:07:55 -0600 Subject: [PATCH 07/13] Dummy commit to trigger build --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 04975bc6..73b232fc 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,7 +23,7 @@ compiler: script: - chmod +x $TRAVIS_BUILD_DIR/.travis/runTests.sh -- sudo docker run -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR +- sudo docker run -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: - if [ "$TRAVIS_BRANCH" = "$TARGET_BRANCH" ] || [ ! -z $TRAVIS_TAG ]; then if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sudo apt-get install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz; fi; fi From 36c17c970195a044a41a399bce75d897a61a55ea Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 17:12:59 -0600 Subject: [PATCH 08/13] Add additional docker options --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 73b232fc..4beefc21 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,7 +23,7 @@ compiler: script: - chmod +x $TRAVIS_BUILD_DIR/.travis/runTests.sh -- sudo docker run -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR +- sudo docker run -rm -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: - if [ "$TRAVIS_BRANCH" = "$TARGET_BRANCH" ] || [ ! -z $TRAVIS_TAG ]; then if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sudo apt-get install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz; fi; fi From 7e9c2387dc4b653be855d5463e090748a3e7635d Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 17:16:11 -0600 Subject: [PATCH 09/13] Edit docker options --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 4beefc21..41409dfd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,7 +23,7 @@ compiler: script: - chmod +x $TRAVIS_BUILD_DIR/.travis/runTests.sh -- sudo docker run -rm -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR +- sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: - if [ "$TRAVIS_BRANCH" = "$TARGET_BRANCH" ] || [ ! -z $TRAVIS_TAG ]; then if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sudo apt-get install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz; fi; fi From f47618612f7cf1031797e1dbd85d5f1ce2ccd360 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 21:39:35 -0600 Subject: [PATCH 10/13] Add more docker parameters --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 41409dfd..7c4cc2de 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,7 +23,7 @@ compiler: script: - chmod +x $TRAVIS_BUILD_DIR/.travis/runTests.sh -- sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR +- sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -e MY_UID=$(id -u) -e MY_GID=$(id -g) -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: - if [ "$TRAVIS_BRANCH" = "$TARGET_BRANCH" ] || [ ! -z $TRAVIS_TAG ]; then if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sudo apt-get install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz; fi; fi From d52b3bf9f823293938a4bae3d6ec1a94b64edab2 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 22:02:12 -0600 Subject: [PATCH 11/13] Add debug info for travis scripts --- .travis.yml | 5 +++++ .travis/runTests.sh | 6 ++++++ 2 files changed, 11 insertions(+) diff --git a/.travis.yml b/.travis.yml index 7c4cc2de..831337c6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,6 +23,11 @@ compiler: script: - chmod +x $TRAVIS_BUILD_DIR/.travis/runTests.sh +- echo "UID" $(id -u) +- echo "GID" $(id -g) +- pwd +- ls -la +- ls -la .. - sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -e MY_UID=$(id -u) -e MY_GID=$(id -g) -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: diff --git a/.travis/runTests.sh b/.travis/runTests.sh index 6a18c32b..08522b4f 100755 --- a/.travis/runTests.sh +++ b/.travis/runTests.sh @@ -6,7 +6,13 @@ CMSSW_VERSION=CMSSW_10_2_9 set -ex TRAVIS_BUILD_DIR=$1 +echo "UID" $(id -u) +echo "GID" $(id -g) +pwd +ls -la cd $TRAVIS_BUILD_DIR/.. +pwd +ls -la export VO_CMS_SW_DIR=/cvmfs/cms.cern.ch export SCRAM_ARCH=slc6_amd64_gcc630 export CMSSW_GIT_REFERENCE=/cvmfs/cms.cern.ch/cmssw.git/ From 2d9ceeb6539b41c9ae357ffc12bb885e4abd22a5 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 22:13:48 -0600 Subject: [PATCH 12/13] Debug test --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 831337c6..01365ce7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,7 +28,7 @@ script: - pwd - ls -la - ls -la .. -- sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -e MY_UID=$(id -u) -e MY_GID=$(id -g) -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR +- sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -e MY_UID=$(id -u) -e MY_GID=$(id -g) -v $TRAVIS_BUILD_DIR/..:$TRAVIS_BUILD_DIR/.. $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: - if [ "$TRAVIS_BRANCH" = "$TARGET_BRANCH" ] || [ ! -z $TRAVIS_TAG ]; then if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sudo apt-get install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz; fi; fi From 457b3155eea3eb8a6c1468060fa256bb7758fdb4 Mon Sep 17 00:00:00 2001 From: Nathaniel Date: Wed, 12 Feb 2020 22:38:40 -0600 Subject: [PATCH 13/13] More travis debug --- .travis.yml | 2 +- .travis/runTests.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 01365ce7..831337c6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,7 +28,7 @@ script: - pwd - ls -la - ls -la .. -- sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -e MY_UID=$(id -u) -e MY_GID=$(id -g) -v $TRAVIS_BUILD_DIR/..:$TRAVIS_BUILD_DIR/.. $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR +- sudo docker run -it -P --device /dev/fuse --cap-add SYS_ADMIN -e CVMFS_MOUNTS="cms.cern.ch oasis.opensciencegrid.org" -e MY_UID=$(id -u) -e MY_GID=$(id -g) -v $TRAVIS_BUILD_DIR:$TRAVIS_BUILD_DIR $DOCKER_CONTAINER $TRAVIS_BUILD_DIR/.travis/runTests.sh $TRAVIS_BUILD_DIR after_success: - if [ "$TRAVIS_BRANCH" = "$TARGET_BRANCH" ] || [ ! -z $TRAVIS_TAG ]; then if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sudo apt-get install doxygen doxygen-doc doxygen-latex doxygen-gui graphviz; fi; fi diff --git a/.travis/runTests.sh b/.travis/runTests.sh index 08522b4f..12747fca 100755 --- a/.travis/runTests.sh +++ b/.travis/runTests.sh @@ -10,7 +10,7 @@ echo "UID" $(id -u) echo "GID" $(id -g) pwd ls -la -cd $TRAVIS_BUILD_DIR/.. +cd /home/cmsuser/ pwd ls -la export VO_CMS_SW_DIR=/cvmfs/cms.cern.ch