ATLAS Offline Software
generator-weights.py
Go to the documentation of this file.
1 #!/usr/bin/env python
2 # Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 
4 from argparse import ArgumentParser
5 from PMGTools.WeightHelpers import weightNameCleanup, weightNameWithPrefix
6 print(dir(PMGTools.WeightHelpers))
7 parser = ArgumentParser(prog='generator-weights')
8 parser.add_argument('weights', metavar='weights', type=str, nargs="+",
9  help="specify the list of weights")
10 parser.add_argument('-p', '--prefixed', default=False, action="store_true",
11  help="add prefix to cleaned weights")
12 args = parser.parse_args()
13 
14 for weight in args.weights:
15  if args.prefixed:
17  else:
18  print(weightNameCleanup(weight))
WeightHelpers.weightNameCleanup
weightNameCleanup
Definition: WeightHelpers.py:7
WeightHelpers.weightNameWithPrefix
weightNameWithPrefix
Definition: WeightHelpers.py:8
beamspotman.dir
string dir
Definition: beamspotman.py:623
Muon::print
std::string print(const MuPatSegment &)
Definition: MuonTrackSteering.cxx:28