This is a class capable of parsing TileCal conditions data stored in
ASCII files.
Definition at line 1502 of file TileCalibTools.py.
◆ __init__()
| def python.TileCalibTools.TileASCIIParser3.__init__ |
( |
|
self, |
|
|
|
fileName, |
|
|
|
calibId |
|
) |
| |
Input:
- fileName : input file name
- calibId : like Trip, ...
Definition at line 1509 of file TileCalibTools.py.
1509 def __init__(self, fileName, calibId):
1512 - fileName : input file name
1513 - calibId : like Trip, ...
1516 TileCalibLogger.__init__(self,
"TileASCIIParser3")
1517 self.__dataDict = {}
1519 lines =
open(fileName,
"r").readlines()
1520 except Exception
as e:
1521 self.log().
error(
"TileCalibASCIIParser3::ERROR: Problem opening input file:" )
1522 self.log().
error( e )
1526 fields = line.strip().
split()
1528 if not len(fields) :
1530 if fields[0].startswith(
"#"):
1540 raise Exception(
"%s is not calibId=%s" % (type, calibId))
1543 if not (frag.startswith(
'0x')
or frag.startswith(
'-0x')):
1544 raise Exception(
"Misformated fragment %s" % frag)
1554 dictKey = (ros, mod)
1555 self.__dataDict[dictKey] = data
◆ getData()
| def python.TileCalibTools.TileASCIIParser3.getData |
( |
|
self, |
|
|
|
ros, |
|
|
|
drawer |
|
) |
| |
◆ getDict()
| def python.TileCalibTools.TileASCIIParser3.getDict |
( |
|
self | ) |
|
◆ __dataDict
| python.TileCalibTools.TileASCIIParser3.__dataDict |
|
private |
The documentation for this class was generated from the following file: