gluonts.transform.field module¶
-
class
gluonts.transform.field.
RemoveFields
(field_names: List[str])[source]¶ Bases:
gluonts.transform._base.SimpleTransformation
” Remove field names if present.
- Parameters
field_names – List of names of the fields that will be removed
-
class
gluonts.transform.field.
RenameFields
(mapping: Dict[str, str])[source]¶ Bases:
gluonts.transform._base.SimpleTransformation
Rename fields using a mapping, if source field present.
- Parameters
mapping – Name mapping input_name -> output_name
-
class
gluonts.transform.field.
SelectFields
(input_fields: List[str])[source]¶ Bases:
gluonts.transform._base.MapTransformation
Only keep the listed fields
- Parameters
input_fields – List of fields to keep.
-
class
gluonts.transform.field.
SetField
(output_field: str, value: Any)[source]¶ Bases:
gluonts.transform._base.SimpleTransformation
Sets a field in the dictionary with the given value.
- Parameters
output_field – Name of the field that will be set
value – Value to be set
-
class
gluonts.transform.field.
SetFieldIfNotPresent
(field: str, value: Any)[source]¶ Bases:
gluonts.transform._base.SimpleTransformation
Sets a field in the dictionary with the given value, in case it does not exist already.
- Parameters
output_field – Name of the field that will be set
value – Value to be set