def report(self, pdf, reportPath):
'''@brief generate this test's page in the PDF report.
@param pdf pyfpdf-compatible PDF object.
@param reportPath Path of directory containing the pdf report'''
onePage = False
if onePage:
pdf.makePlotPage("Parameter Logging: " + name, name + ".jpg",
[(self.data[name], name) for name in self.names])
pdf.cell(0, 6, "Data saved to pickleable object in ParameterLogging.dat with key " + name, 0, 1, 'L')
else:
for name in self.names:
pdf.makePlotPage("Parameter Logging: " + name, name + ".jpg", [(self.data[name], name)])
pdf.cell(0, 6, "Data saved to pickleable object in ParameterLogging.dat with key " + name, 0, 1, 'L')
if dump:
testPath = reportPath + "/" + self.title
os.mkdir(testPath)
with open(testPath + "/data.dat", "wb") as output:
pickle.dump(self.data, output)
评论列表
文章目录