This is a class capable of parsing TileCal conditions data stored in
ASCII files.
Definition at line 1455 of file TileCalibTools.py.
◆ __init__()
def python.TileCalibTools.TileASCIIParser3.__init__ |
( |
|
self, |
|
|
|
fileName, |
|
|
|
calibId |
|
) |
| |
Input:
- fileName : input file name
- calibId : like Trip, ...
Definition at line 1462 of file TileCalibTools.py.
1462 def __init__(self, fileName, calibId):
1465 - fileName : input file name
1466 - calibId : like Trip, ...
1469 TileCalibLogger.__init__(self,
"TileASCIIParser3")
1470 self.__dataDict = {}
1472 lines =
open(fileName,
"r").readlines()
1473 except Exception
as e:
1474 self.log().
error(
"TileCalibASCIIParser3::ERROR: Problem opening input file:" )
1475 self.log().
error( e )
1479 fields = line.strip().
split()
1481 if not len(fields) :
1483 if fields[0].startswith(
"#"):
1493 raise Exception(
"%s is not calibId=%s" % (type, calibId))
1496 if not (frag.startswith(
'0x')
or frag.startswith(
'-0x')):
1497 raise Exception(
"Misformated fragment %s" % frag)
1507 dictKey = (ros, mod)
1508 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: