mirror of
https://github.com/Doctorado-ML/benchmark.git
synced 2025-08-17 00:15:55 +00:00
add nan handling to excel files
This commit is contained in:
@@ -269,7 +269,9 @@ class Excel(BaseReport):
|
|||||||
self._compare_totals = {}
|
self._compare_totals = {}
|
||||||
if book is None:
|
if book is None:
|
||||||
self.excel_file_name = self.file_name.replace(".json", ".xlsx")
|
self.excel_file_name = self.file_name.replace(".json", ".xlsx")
|
||||||
self.book = xlsxwriter.Workbook(self.excel_file_name)
|
self.book = xlsxwriter.Workbook(
|
||||||
|
self.excel_file_name, {"nan_inf_to_errors": True}
|
||||||
|
)
|
||||||
self.set_book_properties()
|
self.set_book_properties()
|
||||||
self.close = True
|
self.close = True
|
||||||
else:
|
else:
|
||||||
@@ -782,7 +784,9 @@ class Benchmark:
|
|||||||
)
|
)
|
||||||
|
|
||||||
def excel(self):
|
def excel(self):
|
||||||
book = xlsxwriter.Workbook(self.get_excel_file_name())
|
book = xlsxwriter.Workbook(
|
||||||
|
self.get_excel_file_name(), {"nan_inf_to_errors": True}
|
||||||
|
)
|
||||||
Excel.set_properties(book, "Experimentation summary")
|
Excel.set_properties(book, "Experimentation summary")
|
||||||
sheet = book.add_worksheet("Benchmark")
|
sheet = book.add_worksheet("Benchmark")
|
||||||
normal = book.add_format({"font_size": 14, "border": 1})
|
normal = book.add_format({"font_size": 14, "border": 1})
|
||||||
|
Reference in New Issue
Block a user