class_docstr: Tracking results to a CSV file.
  
  Also allows monitoring experiments, e.g. by
  
  .. code-block::
  
      tail -f results.txt | grep "hits_at_10"
class_docstr_tok: ["Tracking","results","to","a","CSV","file",".","Also","allows","monitoring","experiments",",","e.g",".","by","..","code-block",":",":","tail","-f","results.txt","|","grep","``","hits_at_10","''"]
docstr: Initialize the tracker.
  
  :param path:
      The path of the log file.
  :param name: The default file name for a file if no path is given. If no default is given,
      the current time is used.
  :param kwargs:
      Additional keyword based arguments forwarded to csv.writer.
docstr_tok: ["Initialize","the","tracker",".",":","param","path",":","The","path","of","the","log","file",".",":","param","name",":","The","default","file","name","for","a","file","if","no","path","is","given",".","If","no","default","is","given",",","the","current","time","is","used",".",":","param","kwargs",":","Additional","keyword","based","arguments","forwarded","to","csv.writer","."]
code: def __init__(
      self,
      path: Union[None, str, pathlib.Path] = None,
      name: Optional[str] = None,
      **kwargs,
  ):
      """Initialize the tracker.
  
      :param path:
          The path of the log file.
      :param name: The default file name for a file if no path is given. If no default is given,
          the current time is used.
      :param kwargs:
          Additional keyword based arguments forwarded to csv.writer.
      """
      super().__init__(path=path, name=name)
      self.csv_writer = csv.writer(self.file, **kwargs)
  
imports: import csv
  import datetime
  import json
  import logging
  import pathlib
  from typing import Any, ClassVar, Mapping, Optional, TextIO, Union
  from .base import ResultTracker
  from ..constants import PYKEEN_LOGS
  from ..utils import flatten_dictionary, normalize_path
label_desc: Use image node_id 1 to create a new CSVResultTracker object from inherited base classes: FileResultTracker with example: obj = CSVResultTracker(path, name)