parameters: (self, estimator)
docstring: A setter called automatically by the target estimator.
  
      Args:
        estimator: the estimator that this monitor monitors.
  
      Raises:
        ValueError: if the estimator is None.
docstring_summary: A setter called automatically by the target estimator.
docstring_tokens: A setter called automatically by the target estimator .
function: def set_estimator(self, estimator):
      """A setter called automatically by the target estimator.
  
      Args:
        estimator: the estimator that this monitor monitors.
  
      Raises:
        ValueError: if the estimator is None.
      """
      if estimator is None:
        raise ValueError("Missing estimator.")
      # TODO(mdan): This should fail if called twice with the same estimator.
      self._estimator = estimator
function_tokens: def set_estimator ( self , estimator ) : if estimator is None : raise ValueError ( "Missing estimator." ) # TODO(mdan): This should fail if called twice with the same estimator. self . _estimator = estimator