class_docstr: Scheduling based on polynomial equation.
  
  s(t) = start_value for t < begin_step
  
       = end_value + [(start_value - end_value) * (1 - decay_term) ** exponent]
  
       where decay_term = (t - begin_step) / decay_steps
  
             for 0 <= 1 - decay_term <= 1
                 <-> 0 <= decay_term <= 1
                 <-> 0 <= (t - begin_step) / decay_steps <= 1
                 <-> 0 <= (t - begin_step) <= decay_steps
                 <-> begin_step <= t <= begin_step + decay_steps (=end_step)
  
       = end_value   for t > begin_step + decay_steps (=end_step)
docstr: Initialize PolynomialDecayScheduler.
  
  Args:
    start_value: the initial value of decaying. It is also the default value
      of this scheduler for step <= begin_step.
    decay_steps: A Python positive int value for duration of decaying.
    end_value: the final value of decaying. It is also the default value of
      this scheduler for step >= end_step = begin_step + decay_steps
    begin_step: The step value that this scheduler starts decaying.
      Defaults to 0, which means it decays right after training starts.
    exponent: The exponent of the polynomial decaying.
      Defaults to 1.0, a linear function.
    dtype: `tf.dtypes.DType`, dtype of returned tensor.
      Defaults to tf.float32.
    name: A Python `str` for the name scope of this scheduler.
  
  Returns:
    A `tf.Tensor` of the scheduled output value calculated from the polynomial
    equation as given above.
docstr_tok: ["Initialize","PolynomialDecayScheduler",".","Args",":","start_value",":","the","initial","value","of","decaying",".","It","is","also","the","default","value","of","this","scheduler","for","step","<","=","begin_step",".","decay_steps",":","A","Python","positive","int","value","for","duration","of","decaying",".","end_value",":","the","final","value","of","decaying",".","It","is","also","the","default","value","of","this","scheduler","for","step",">","=","end_step","=","begin_step","+","decay_steps","begin_step",":","The","step","value","that","this","scheduler","starts","decaying",".","Defaults","to","0",",","which","means","it","decays","right","after","training","starts",".","exponent",":","The","exponent","of","the","polynomial","decaying",".","Defaults","to","1.0",",","a","linear","function",".","dtype",":","`","tf.dtypes.DType","`",",","dtype","of","returned","tensor",".","Defaults","to","tf.float32",".","name",":","A","Python","`","str","`","for","the","name","scope","of","this","scheduler",".","Returns",":","A","`","tf.Tensor","`","of","the","scheduled","output","value","calculated","from","the","polynomial","equation","as","given","above","."]
code: def __init__(
      self,
      start_value: Union[int, float],
      decay_steps: int,
      end_value: Union[int, float],
      begin_step: Optional[int] = 0,
      exponent: Optional[float] = 1.0,
      dtype: Optional[tf.dtypes.DType] = tf.float32,
      name: Optional[str] = None,
  ):
      """Initialize PolynomialDecayScheduler.
  
      Args:
        start_value: the initial value of decaying. It is also the default value
          of this scheduler for step <= begin_step.
        decay_steps: A Python positive int value for duration of decaying.
        end_value: the final value of decaying. It is also the default value of
          this scheduler for step >= end_step = begin_step + decay_steps
        begin_step: The step value that this scheduler starts decaying.
          Defaults to 0, which means it decays right after training starts.
        exponent: The exponent of the polynomial decaying.
          Defaults to 1.0, a linear function.
        dtype: `tf.dtypes.DType`, dtype of returned tensor.
          Defaults to tf.float32.
        name: A Python `str` for the name scope of this scheduler.
  
      Returns:
        A `tf.Tensor` of the scheduled output value calculated from the polynomial
        equation as given above.
      """
      self.name = name
      self.start_value = start_value
      self.begin_step = begin_step
      self.end_value = end_value
      self.decay_steps = decay_steps
      self.end_step = self.begin_step + self.decay_steps
      self.exponent = exponent
      self.dtype = dtype
  
file_path: model-optimization/tensorflow_model_optimization/python/core/common/keras/compression/schedules.py
imports: import abc
  from typing import Union, Optional
  import tensorflow
label_desc: Use image node_id 1 to create a new PolynomialDecay object from inherited base classes: Scheduler with example: obj = PolynomialDecay(start_value, decay_steps, end_value, begin_step, exponent, dtype, name)