uis-rnn icon indicating copy to clipboard operation
uis-rnn copied to clipboard

Add a `online_predict()` API for streaming input

Open wq2012 opened this issue 5 years ago • 3 comments

UIS-RNN is an online algorithm, but the current predict() API of this library is not.

If people want to deploy this library to a production environment for online use cases, an online_predict() API is going to be necessary.

Its usage should be like this:

# Feed the first sequence, and continuously make use of the label.
label = model.online_predict(X1)
label = model.online_predict(X2)
label = model.online_predict(X3)
model.online_predict(reset=True)
# Feed the second sequence, and continuously make use of the label.
label = model.online_predict(Y1)
label = model.online_predict(Y2)
label = model.online_predict(Y3)
label = model.online_predict(Y4)
model.online_predict(reset=True)

However, we may not have the bandwidth to work on this any time soon.

wq2012 avatar Jan 29 '19 17:01 wq2012

Any update on this?

sukhbirsinghsaini avatar Jan 06 '20 17:01 sukhbirsinghsaini

Unfortunately, as several core members have left the team, we won't be able to work on this ourselves.

But if someone wants to work on this, he/she can create a subclass of UISRNN under the contrib directory. We would welcome that.

wq2012 avatar Jan 06 '20 20:01 wq2012

UIS-RNN is an online algorithm, but the current predict() API of this library is not.

If people want to deploy this library to a production environment for online use cases, an online_predict() API is going to be necessary.

Its usage should be like this:

# Feed the first sequence, and continuously make use of the label.
label = model.online_predict(X1)
label = model.online_predict(X2)
label = model.online_predict(X3)
model.online_predict(reset=True)
# Feed the second sequence, and continuously make use of the label.
label = model.online_predict(Y1)
label = model.online_predict(Y2)
label = model.online_predict(Y3)
label = model.online_predict(Y4)
model.online_predict(reset=True)

However, we may not have the bandwidth to work on this any time soon.

can you give some ideas?

hbo-lambda avatar Jul 26 '21 05:07 hbo-lambda