class monad.targets.DataSourceAttributes
monad.targets.DataSourceAttributesContains main entity attribute data source defined in the pretrain phase.
Methods
DataSourceAttributes.__getitem__(self, column_name)
DataSourceAttributes.__getitem__(self, column_name)def target_fn(history: Events, future: Events, attributes: Attributes, ctx: Dict) -> np.ndarray:
# below we get the age attribute from the datasource 'customers'
# note it is a ModalityAttribute object, not the value of the attribute
age = attributes["customers"]["age"]
...
| Parameters |
|---|
column_name: str | list[str]
Name of the attribute from the data source.
| Returns |
|---|
