ATLAS Offline Software
Loading...
Searching...
No Matches
dumpTgcDigiThreshold Namespace Reference

Functions

 setupArgParser ()

Variables

 args = setupArgParser().parse_args()
 resolver = PathResolver()
 resolvedInFile = resolver.find_file(args.inFile, "DATAPATH")
dict stationNameDict = {41:"T1F", 42:"T1E", 43:"T2F", 44:"T2E", 45:"T3F", 46:"T3E", 47:"T4F", 48:"T4E"}
 translate the station name indices into the string staiton name
list threshChambers = []
 line = line[0 : line.find("#")]
list tokens = [x.strip() for x in line.split(" ") if len(x.strip())]
dict stationName = stationNameDict[int(tokens[0])]
list stationEta = tokens[1][tokens[1].find("+")+1: ]
list stationPhi = tokens[2]
list gasGap = tokens[3]
list isStrip = tokens[4]
list threshold = tokens[5]
str threshEntry

Function Documentation

◆ setupArgParser()

dumpTgcDigiThreshold.setupArgParser ( )

Definition at line 3 of file dumpTgcDigiThreshold.py.

3def setupArgParser():
4 from argparse import ArgumentParser
5
6 parser = ArgumentParser()
7 parser.add_argument("--inFile", help="Input file to be translated",
8 default="TGC_Digitization_energyThreshold.dat")
9 parser.add_argument("--outFile", help="Output JSON file",
10 default="TGC_Digitization_energyThreshold.json")
11 return parser
12

Variable Documentation

◆ args

dumpTgcDigiThreshold.args = setupArgParser().parse_args()

Definition at line 14 of file dumpTgcDigiThreshold.py.

◆ gasGap

list dumpTgcDigiThreshold.gasGap = tokens[3]

Definition at line 32 of file dumpTgcDigiThreshold.py.

◆ isStrip

list dumpTgcDigiThreshold.isStrip = tokens[4]

Definition at line 33 of file dumpTgcDigiThreshold.py.

◆ line

dumpTgcDigiThreshold.line = line[0 : line.find("#")]

Definition at line 27 of file dumpTgcDigiThreshold.py.

◆ resolvedInFile

dumpTgcDigiThreshold.resolvedInFile = resolver.find_file(args.inFile, "DATAPATH")

Definition at line 18 of file dumpTgcDigiThreshold.py.

◆ resolver

dumpTgcDigiThreshold.resolver = PathResolver()

Definition at line 16 of file dumpTgcDigiThreshold.py.

◆ stationEta

list dumpTgcDigiThreshold.stationEta = tokens[1][tokens[1].find("+")+1: ]

Definition at line 30 of file dumpTgcDigiThreshold.py.

◆ stationName

dict dumpTgcDigiThreshold.stationName = stationNameDict[int(tokens[0])]

Definition at line 29 of file dumpTgcDigiThreshold.py.

◆ stationNameDict

dict dumpTgcDigiThreshold.stationNameDict = {41:"T1F", 42:"T1E", 43:"T2F", 44:"T2E", 45:"T3F", 46:"T3E", 47:"T4F", 48:"T4E"}

translate the station name indices into the string staiton name

Definition at line 23 of file dumpTgcDigiThreshold.py.

◆ stationPhi

list dumpTgcDigiThreshold.stationPhi = tokens[2]

Definition at line 31 of file dumpTgcDigiThreshold.py.

◆ threshChambers

list dumpTgcDigiThreshold.threshChambers = []

Definition at line 24 of file dumpTgcDigiThreshold.py.

◆ threshEntry

str dumpTgcDigiThreshold.threshEntry
Initial value:
1= "\n".join([ " {",
2 " \"station\" : \"{name}\",".format(name = stationName),
3 " \"eta\" : {eta},".format(eta = stationEta),
4 " \"phi\" : {phi},".format(phi = stationPhi),
5 " \"gasGap\" : {gap},".format(gap = gasGap),
6 " \"isStrip\" : {strip},".format(strip = isStrip),
7 " \"threshold\": {threshold}".format(threshold=threshold),
8 " }"])

Definition at line 35 of file dumpTgcDigiThreshold.py.

◆ threshold

list dumpTgcDigiThreshold.threshold = tokens[5]

Definition at line 34 of file dumpTgcDigiThreshold.py.

◆ tokens

list dumpTgcDigiThreshold.tokens = [x.strip() for x in line.split(" ") if len(x.strip())]

Definition at line 28 of file dumpTgcDigiThreshold.py.