code: def _log_epoch(
      self,
      epoch,
      timedelta,
      sub_train,
      sub_valid,
      train_acc,
      train_loss,
      valid_acc,
      valid_loss,
  ):
      if sub_valid is not None:
          valid_loss_txt = f"\n\tLoss: {valid_loss:.4f}(valid)\t|\tAcc: {valid_acc * 100:.1f}%(valid)"
      else:
          valid_loss_txt = ""
      self.logger.info(
          f"Epoch: {epoch + 1} | {format_timedelta(timedelta)}\n"
          f"\tTrain Set Size: {len(sub_train)}\n"
          f"\tLoss: {train_loss:.4f}(train)\t|\tAcc: {train_acc * 100:.1f}%(train)"
          f"{valid_loss_txt}",
          verbosity=VERBOSITY_MORE_VERBOSE,
      )
  
imports: import datetime
  import logging
  import tempfile
  import warnings
  import numpy
  from functools import partial
  from small_text.classifiers.classification import EmbeddingMixin
  from small_text.integrations.pytorch.exceptions import PytorchNotFoundError
  from small_text.utils.classification import get_splits
  from small_text.utils.context import build_pbar_context
  from small_text.utils.data import check_training_data, list_length
  from small_text.utils.datetime import format_timedelta
  from small_text.utils.annotations import early_stopping_deprecation_warning, model_selection_deprecation_warning
  from small_text.utils.labels import get_num_labels
  from small_text.utils.logging import verbosity_logger, VERBOSITY_MORE_VERBOSE
  from small_text.utils.system import get_tmp_dir_base
label_desc: Use image node_id 12 for calling the TransformerBasedClassification obj's underlying member method code with example usage: obj._log_epoch(epoch, timedelta, sub_train, sub_valid, train_acc, train_loss, valid_acc, valid_loss) without return types