2Input/output of MP-II binary records.
96 self.
__glder = array.array(
'd' if doublePrec
else 'f')
108 aMeas, aPrec, indLocal, derLocal, labGlobal, derGlobal = dataList
111 self.
__inder.fromlist(indLocal)
112 self.
__glder.fromlist(derLocal)
114 self.
__glder.append(1.0 / math.sqrt(aPrec))
115 self.
__inder.fromlist(labGlobal)
116 self.
__glder.fromlist(derGlobal)
127 indLocal.append(self.
__inder[i])
128 derLocal.append(self.
__glder[i])
133 indGlobal.append(self.
__inder[i])
134 derGlobal.append(self.
__glder[i])
135 return aMeas, aPrec, indLocal, derLocal, indGlobal, derGlobal
139 print(
" MilleRecord, len: ", len(self.
__inder))
148 header = array.array(
'i')
159 header = array.array(
'i')
160 header.fromfile(aFile, 1)
163 self.
__glder = array.array(
'd')
Millepede-II (binary) record.
__numData
number of data blocks in record; int
def specialDataTag(self)
Get special data tag from block.
def __init__(self, doublePrec=False)
Create MP-II binary record.
__doublePrecision
flag for storage in as double values
def getData(self)
Get data block from current position in record.
__iMeas
position of value in current data block; int
__glder
array with values, errors and derivatives; (float32 or float64)
def moreData(self)
Locate next data block.
def addData(self, dataList)
Add data block to (end of) record.
__inder
array with markers (0) and labels; array(int32)
__position
position in record, usually start of next data block; int
__recLen
record length; int
def writeRecord(self, aFile)
Write record to file.
__iErr
position of error in current data block; int
def printRecord(self)
Print record.
def readRecord(self, aFile)
Read record from file.