docstr: Base class for other classes that record various Experiment result files. Critical
  attributes of the descendants of :class`recorders.BaseRecorder` are set here, enabling them
  to function properly
  
  Returns
  -------
  None
      If :attr:`result_path` is None, which means the present result file was blacklisted by
      the active Environment
  
  Raises
  ------
  EnvironmentInactiveError
      If :attr:`settings.G.Env` is None
  EnvironmentInvalidError
      If any of the following occur: 1) :attr:`settings.G.Env` does not have an attribute
      named 'result_paths', 2) :attr:`settings.G.Env.result_paths` does not contain the
      current `result_path_key`, 3) :attr:`settings.G.Env.current_task` is None
docstr_tok: ["Base","class","for","other","classes","that","record","various","Experiment","result","files",".","Critical","attributes","of","the","descendants","of",":","class","`","recorders.BaseRecorder","`","are","set","here",",","enabling","them","to","function","properly","Returns","--","--","--","-","None","If",":","attr",":","`","result_path","`","is","None",",","which","means","the","present","result","file","was","blacklisted","by","the","active","Environment","Raises","--","--","--","EnvironmentInactiveError","If",":","attr",":","`","settings.G.Env","`","is","None","EnvironmentInvalidError","If","any","of","the","following","occur",":","1",")",":","attr",":","`","settings.G.Env","`","does","not","have","an","attribute","named","'result_paths","'",",","2",")",":","attr",":","`","settings.G.Env.result_paths","`","does","not","contain","the","current","`","result_path_key","`",",","3",")",":","attr",":","`","settings.G.Env.current_task","`","is","None"]
code: def __init__(self):
      """Base class for other classes that record various Experiment result files. Critical
      attributes of the descendants of :class`recorders.BaseRecorder` are set here, enabling them
      to function properly
  
      Returns
      -------
      None
          If :attr:`result_path` is None, which means the present result file was blacklisted by
          the active Environment
  
      Raises
      ------
      EnvironmentInactiveError
          If :attr:`settings.G.Env` is None
      EnvironmentInvalidError
          If any of the following occur: 1) :attr:`settings.G.Env` does not have an attribute
          named 'result_paths', 2) :attr:`settings.G.Env.result_paths` does not contain the
          current `result_path_key`, 3) :attr:`settings.G.Env.current_task` is None
      """
      self.result_path = None
      self.result = None
  
      ##################################################
      # Get Result Path for Record, or Exit Early
      ##################################################
      try:
          self.result_path = G.Env.result_paths[self.result_path_key]
      except AttributeError as _ex:
          if G.Env is None:
              raise EnvironmentInactiveError(str(_ex)).with_traceback(
                  exc_info()[2]
              )
          if not hasattr(G.Env, "result_paths"):
              _err_message = (
                  f"{_ex!s}\nG.Env missing 'result_paths' attr"
              )
              raise EnvironmentInvalidError(
                  _err_message
              ).with_traceback(exc_info()[2])
      except KeyError as _ex:
          _err_message = f"{_ex!s}\nG.Env.result_paths missing the key: '{self.result_path_key}'"
          raise EnvironmentInvalidError(_err_message).with_traceback(
              exc_info()[2]
          )
  
      if self.result_path is None:
          return  # Result file blacklisted and should not be recorded. Kill recording process now
  
      ##################################################
      # Gather Attributes Required for Record
      ##################################################
      for required_attribute in self.required_attributes:
          try:
              setattr(
                  self,
                  required_attribute,
                  getattr(G.Env.current_task, required_attribute),
              )
          except AttributeError as _ex:
              if G.Env.current_task is None:
                  _err_message = f"{_ex!s}\nNo active experiment found"
                  raise EnvironmentInvalidError(
                      _err_message
                  ).with_traceback(exc_info()[2])
              raise EnvironmentInvalidError(str(_ex)).with_traceback(
                  exc_info()[2]
              )
  
imports: from hyperparameter_hunter.data import OOFDataset, HoldoutDataset, TestDataset
  from hyperparameter_hunter.i_o.exceptions import EnvironmentInactiveError, EnvironmentInvalidError
  from hyperparameter_hunter.i_o.leaderboards import GlobalLeaderboard
  from hyperparameter_hunter.settings import G
  from hyperparameter_hunter.utils.file_utils import write_json, add_to_json, make_dirs, read_json
  from hyperparameter_hunter.utils.file_utils import RetryMakeDirs
  from hyperparameter_hunter.utils.general_utils import subdict
  from abc import ABCMeta, abstractmethod
  from collections import OrderedDict
  from platform import node
  import shutil
  from sys import exc_info
label_desc: Use image node_id 1 to create a new BaseRecorder object  with example: obj = BaseRecorder()