class_docstr: Callback that outputs the result of each epoch_number or batch into a Tensorboard experiment folder.
  
  Args:
      writer (~torch.utils.tensorboard.writer.SummaryWriter): The tensorboard writer.
      split_train_val (bool): Whether to put each training and validation metric in the same graphs.
          (Default = False)
  
  Example:
      Using TensorBoardLogger::
  
          from torch.utils.tensorboard import SummaryWriter
          from poutyne import Model, TensorBoardLogger
  
          writer = SummaryWriter('runs')
          tb_logger = TensorBoardLogger(writer)
  
          model = Model(...)
          model.fit_generator(..., callbacks=[tb_logger])
class_docstr_tok: ["Callback","that","outputs","the","result","of","each","epoch_number","or","batch","into","a","Tensorboard","experiment","folder",".","Args",":","writer","(","~torch.utils.tensorboard.writer.SummaryWriter",")",":","The","tensorboard","writer",".","split_train_val","(","bool",")",":","Whether","to","put","each","training","and","validation","metric","in","the","same","graphs",".","(","Default","=","False",")","Example",":","Using","TensorBoardLogger",":",":","from","torch.utils.tensorboard","import","SummaryWriter","from","poutyne","import","Model",",","TensorBoardLogger","writer","=","SummaryWriter","(","'runs","'",")","tb_logger","=","TensorBoardLogger","(","writer",")","model","=","Model","(","...",")","model.fit_generator","(","...",",","callbacks=","[","tb_logger","]",")"]
code: def _on_train_end_write(self, logs: Dict):
      self.writer.close()
  
imports: import csv
  import os
  from typing import Dict, Optional, TextIO
  from poutyne.framework.callbacks._utils import atomic_lambda_save
  from poutyne.framework.callbacks.callbacks import Callback
label_desc: Use image node_id 4 for calling the TensorBoardLogger obj's underlying member method code with example usage: obj._on_train_end_write(logs) without return types