class_docstr: Expands a `const` value along the time axis as a dynamic feature, where the
  T-dimension is defined as the sum of the `pred_length` parameter and the
  length of a time series specified by the `target_field`.
  
  If `is_train=True` the feature matrix has the same length as the `target`
  field. If `is_train=False` the feature matrix has length
  `len(target) + pred_length`.
  
  Parameters
  ----------
  output_field
      Field name for output.
  target_field
      Field containing the target array. The length of this array will be
      used.
  pred_length
      Prediction length (this is necessary since features have to be
      available in the future)
  const
      Constant value to use.
  dtype
      Numpy dtype to use for resulting array.
class_docstr_tok: ["Expands","a","`","const","`","value","along","the","time","axis","as","a","dynamic","feature",",","where","the","T-dimension","is","defined","as","the","sum","of","the","`","pred_length","`","parameter","and","the","length","of","a","time","series","specified","by","the","`","target_field","`",".","If","`","is_train=True","`","the","feature","matrix","has","the","same","length","as","the","`","target","`","field",".","If","`","is_train=False","`","the","feature","matrix","has","length","`","len","(","target",")","+","pred_length","`",".","Parameters","--","--","--","--","--","output_field","Field","name","for","output",".","target_field","Field","containing","the","target","array",".","The","length","of","this","array","will","be","used",".","pred_length","Prediction","length","(","this","is","necessary","since","features","have","to","be","available","in","the","future",")","const","Constant","value","to","use",".","dtype","Numpy","dtype","to","use","for","resulting","array","."]
code: def __init__(
      self,
      output_field: str,
      target_field: str,
      pred_length: int,
      const: float = 1.0,
      dtype: Type = np.float32,
  ) -> None:
      self.pred_length = pred_length
      self.const = const
      self.dtype = dtype
      self.output_field = output_field
      self.target_field = target_field
  
imports: from typing import List, Optional, Union, Type
  import numpy
  import pandas
  from gluonts.core.component import validated
  from gluonts.dataset.common import DataEntry
  from gluonts.dataset.field_names import FieldName
  from gluonts.time_feature import TimeFeature
  from ._base import MapTransformation, SimpleTransformation
label_desc: Use image node_id 1 to create a new AddConstFeature object from inherited base classes: MapTransformation with example: obj = AddConstFeature(output_field, target_field, pred_length, const, dtype)