Skip to content

Instantly share code, notes, and snippets.

@riga
Created November 27, 2019 14:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save riga/822343f7e40bdeb759d96d342a2537e8 to your computer and use it in GitHub Desktop.
Save riga/822343f7e40bdeb759d96d342a2537e8 to your computer and use it in GitHub Desktop.
cmsdist and cmssw setup for tf2.0
action() {
local base="$( /bin/pwd )"
git clone https://github.com/cms-sw/pkgtools.git
git clone --single-branch --branch tf-2.0 https://github.com/riga/cmsdist.git
./pkgtools/cmsBuild -i tf-2.0 -c cmsdist/ --repository cms.week0 --arch slc7_amd64_gcc820 -j 10 build cmssw-tool-conf --no-cleanup
export SCRAM_ARCH="slc7_amd64_gcc820"
export CMSSW_VERSION="CMSSW_11_0_0_pre12"
scramv1 project CMSSW "$CMSSW_VERSION"
cd "$CMSSW_VERSION/config/toolbox/$SCRAM_ARCH/tools"
rm -rf available selected
cp -r $base/tf-2.0/$SCRAM_ARCH/cms/cmssw-tool-conf/45.0-cms/tools/* .
cd "$base/$CMSSW_VERSION"
scram setup
cd src
eval `scramv1 runtime -sh`
git cms-init
git cms-addpkg PhysicsTools/TensorFlow
rm -f PhysicsTools/TensorFlow/{src,interface}/{NTSession.*,TBBSession.*}
scram b -j
}
action "$@"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment