I'm training a model with a set of time series; each time series have two arrays of exactly 2880 values each.
For each of the time series, I have a label as well.
This is my data:
type ContractData =
{
[<ColumnName("Prices"); VectorType(2880)>]
Prices: single array
[<ColumnName("Volumes"); VectorType(2880)>]
Volumes: single array
[<ColumnName("Direction")>]
Direction: single
}
And the pipeline has nothing special:
let dataProcessPipeline =
EstimatorChain()
.Append(mlContext.Transforms.CopyColumns("Features", "Prices"))
.Append(mlContext.Transforms.CopyColumns("Label", "Direction"))
.AppendCacheCheckpoint(mlContext)
I have a first question: The Prices and Volumes array represent values that go together: Price[5] has a volume of Volumes[5]. Is there a way to explicitly describe that relationship?
My goal is to classify partial time series (they're in progress, so the starting points are always the same), which don't have the 2880 values yet. But when I call Predict with a time series that is partial, I get the follower error:
System.InvalidOperationException: Operation is not valid due to the current state of the object.
How can I build this?