# biome.text.loggers Module

# add_default_wandb_logger_if_needed Function


def add_default_wandb_logger_if_needed(loggers: List[BaseTrainLogger]) -> NoneType

Adds the default WandBLogger if a WandB login is detected and no WandBLogger is found in loggers.

Parameters

loggers
List of loggers used in the training

# BaseTrainLogger Class


class BaseTrainLogger ()

Base train logger for pipeline training

# Ancestors

  • allennlp.training.trainer.EpochCallback
  • allennlp.common.registrable.Registrable
  • allennlp.common.from_params.FromParams

# Subclasses

# init_train Method


def init_train (
  self,
  pipeline: Pipeline,
  trainer_configuration: TrainerConfiguration,
  training: Union[allennlp.data.dataset_readers.dataset_reader.AllennlpDataset, allennlp.data.dataset_readers.dataset_reader.AllennlpLazyDataset],
  validation: Union[allennlp.data.dataset_readers.dataset_reader.AllennlpDataset, allennlp.data.dataset_readers.dataset_reader.AllennlpLazyDataset, NoneType] = None,
  test: Union[allennlp.data.dataset_readers.dataset_reader.AllennlpDataset, allennlp.data.dataset_readers.dataset_reader.AllennlpLazyDataset, NoneType] = None,
) 

Init train logging

Parameters

pipeline: The training pipeline trainer_configuration: The trainer configuration training: Training dataset validation: Validation dataset test: Test dataset

# end_train Method


def end_train (
  self,
  results: TrainingResults,
) 

End train logging

Parameters

results: The training result set

# log_epoch_metrics Method


def log_epoch_metrics (
  self,
  epoch: int,
  metrics: Dict[str, Any],
) 

Log epoch metrics

Parameters

epoch: The current epoch metrics: The metrics related to current epoch

# MlflowLogger Class


class MlflowLogger (
    experiment_name: str = None,
    artifact_location: str = None,
    run_name: str = None,
    **tags,
)

A common mlflow logger for pipeline training

Parameters

experiment_name: The experiment name artifact_location: The artifact location used for this experiment run_name: If specified, set a name to created run tags: Extra arguments used as tags to created experiment run

# Ancestors

  • BaseTrainLogger
  • allennlp.training.trainer.EpochCallback
  • allennlp.common.registrable.Registrable
  • allennlp.common.from_params.FromParams

# Inherited members

# WandBLogger Class


class WandBLogger (
    project_name: str = 'biome',
    run_name: str = None,
    tags: List[str] = None,
)

Logger for WandB

Parameters

project_name
Name of your WandB project
run_name
Name of your run
tags
Extra arguments used as tags to created experiment run

# Ancestors

  • BaseTrainLogger
  • allennlp.training.trainer.EpochCallback
  • allennlp.common.registrable.Registrable
  • allennlp.common.from_params.FromParams

# Inherited members

Maintained by