Stop&Hop learns to encode ongoing irregular time series via continuous time representation learning, computing vector representations of a series \(X\)  at real-valued timesteps.
We refer to this as a Prefix Encoder, as it encodes the prefixes of ongoing time series.
There has been a recent surge in approaches developed for representing ongoing ITS [1]}, [2]} and most use a recurrent component to encode the series at real-valued timesteps in the continuous timeline:
\(h_t^\prime = \mathcal {R}_\theta (X, t^\prime )\) , where \(R(\cdot )\)  is a continuous-time recurrent neural network and \(t^\prime \)  is a real-valued time. \(h_t^\prime \)  is thus a vector representing all dynamics of observations in series \(X\)  prior to time \(t^\prime \) , including information found in the irregularity of the values. The only constraint on architecture design for \(\mathcal {R}_\theta (\cdot )\)  in the Early Classification setting is that \(h_t^\prime \)  must only be computed with respect to values observed earlier than \(t^\prime \) .
This disables the use of methods that compute bi-directional hidden states or use future values for imputation [3]}.
Further, we seek to model the irregularity itself, which can inform both the classification accuracy and the earliness.
Thus we compute \(h_{t^\prime }\)  using the GRU-D [1]}, denoted for variable step sizes between embeddings.
The hidden state and input values are decayed based on the time since the
last-observed value for each variable as follows:
\(\hat{x}^d_{t^\prime } &= m_{t^\prime }^dx_{t^\prime }^d \odot (1-m^d_{t^\prime })(\gamma _{x_{t^\prime }}^dx_{\text{prev}}^d + (1-\gamma _{x_{t^\prime }}^d\tilde{x}^d_{t^\prime }))\\\hat{h}_{t^\prime } &= \gamma _{h_t} \odot h_{t^\prime }\\r_{t^\prime } &= \sigma (W_r\hat{x}_{t^\prime } + U_r\hat{h}_{t^\prime } + b_r)\\z_{t^\prime } &= \sigma (W_z\hat{x}_{t^\prime } + U_z\hat{h}_{t^\prime } + b_z)\\\tilde{h}_{t^\prime } &= \phi (W\hat{x}_{t^\prime } + U(r_{t^\prime } \odot \hat{h}_{t^\prime }) + Vm_{t^\prime } + b)\\h_{t^\prime } &:= (1-z_{t^\prime }) \odot h_{t^\prime } + z_t \odot \tilde{h}_{t^\prime },\) 
