def log_metrics(
        self,
        metrics: Dict[str, float],
        scope: str,
        runner: "IRunner",
    ) -> None:
        """Logs batch, epoch and loader metrics to Neptune."""
        if scope == "batch" and self.log_batch_metrics:
            neptune_path = "/".join([self.base_namespace, runner.loader_key, scope])
            self._log_metrics(
                metrics=metrics, neptune_path=neptune_path, step=runner.sample_step
            )
        elif scope == "loader" and self.log_epoch_metrics:
            neptune_path = "/".join([self.base_namespace, runner.loader_key, scope])
            self._log_metrics(
                metrics=_prepare_metrics(metrics),
                neptune_path=neptune_path,
                step=runner.epoch_step,
            )
        elif scope == "epoch" and self.log_epoch_metrics:
            loader_key = "_epoch_"
            prepared_metrics = _prepare_metrics(metrics[loader_key])
            neptune_path = "/".join([self.base_namespace, scope])
            if prepared_metrics:
                self._log_metrics(
                    metrics=prepared_metrics,
                    neptune_path=neptune_path,
                    step=runner.epoch_step,
                )
        elif scope == "experiment" or scope is None:
            self._log_metrics(metrics=metrics, neptune_path=self.base_namespace, step=0)
Logs batch, epoch and loader metrics to Neptune.
catalyst/loggers/neptune.py