tensorflow/models · error · ValueError

Smart Bias is only supported currently with alinear warm up.

Error message

Smart Bias is only supported currently with alinear warm up.

What it means

Error "Smart Bias is only supported currently with alinear warm up." thrown in tensorflow/models.

Source

Thrown at official/projects/yolo/optimization/optimizer_factory.py:86

    Builds learning rate from config. Learning rate schedule is built according
    to the learning rate config. If learning rate type is consant,
    lr_config.learning_rate is returned.

    Args:
      bias_lr: learning rate config.

    Returns:
      tf_keras.optimizers.schedules.LearningRateSchedule instance. If
      learning rate type is consant, lr_config.learning_rate is returned.
    """
    if self._lr_type == 'constant':
      lr = self._lr_config.learning_rate
    else:
      lr = LR_CLS[self._lr_type](**self._lr_config.as_dict())

    if self._warmup_config:
      if self._warmup_type != 'linear':
        raise ValueError('Smart Bias is only supported currently with a'
                         'linear warm up.')
      warm_up_cfg = self._warmup_config.as_dict()
      warm_up_cfg['warmup_learning_rate'] = bias_lr
      lr = WARMUP_CLS['linear'](lr, **warm_up_cfg)
    return lr

  @gin.configurable
  def add_ema(self, optimizer):
    """Add EMA to the optimizer independently of the build optimizer method."""
    if self._use_ema:
      optimizer = ema_optimizer.ExponentialMovingAverage(
          optimizer, **self._ema_config.as_dict())
    return optimizer

View on GitHub (pinned to e006f5f0d5)

When it happens

Trigger: Thrown at official/projects/yolo/optimization/optimizer_factory.py:86 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of tensorflow/models@e006f5f0d5 (2026-08-24). Data as JSON: /api/errors/dac26e01fc311d77. Report an issue: GitHub.