↑ Time Series Features
Timeseries features are handled as sequence features, with the only difference being that the matrix in the HDF5 preprocessing file uses floats instead of integers.
Since data is continuous, the JSON file, which typically stores vocabulary mappings, isn't needed.
Time series encoders are the same as for Sequence Features, with one exception:
Time series features don't have an embedding layer at the beginning, so the
b x s placeholders (where
b is the batch
s is the sequence length) are directly mapped to a
b x s x 1 tensor and then passed to the different
The encoder parameters specified at the feature level are:
null): name of another input feature to tie the weights of the encoder with. It needs to be the name of a feature of the same type and with the same encoder parameters.
Example category feature entry in the input features list:
A["12\n7\n43\n65\n23\n4\n1"] --> B["Cast float32"];
B --> C["Aggregation\n Reduce\n Operation"];
C --> ...;
The passthrough encoder simply transforms each input value into a float value and adds a dimension to the input tensor,
b x s x 1 tensor where
b is the batch size and
s is the length of the sequence.
The tensor is reduced along the
s dimension to obtain a single vector of size
h for each element of the batch.
If you want to output the full
b x s x h tensor, you can specify
This encoder is not really useful for
text features, but may be useful for
timeseries features, as it
allows for using them without any processing in later stages of the model, like in a sequence combiner for instance.
null): The size of the encoding vector, or None if sequence elements are scalars.
null): How to reduce the output tensor along the
ssequence length dimension if the rank of the tensor is greater than 2. Options:
There are no time series decoders at the moment.
If this would unlock an interesting use case for your application, please file a GitHub Issue or ping the Ludwig Slack.