After training, can I send it another stream to be processed using the "trained" classifier?
Yes, there is a way to run another evaluation task with a previously trained model. You must first make sure to set the parameter
EvaluatePrequential. This way the firsst
evaluate call will train the model without restarting it at the end. If you call again
evaluate with a new stream and the same model, the model will continue learning.
@jacobmontiel Jacob, if I don't want the model to continue learning, should I set restart_stream=True or False?
This parameter is not intended to be used like that. This parameter indicates if the model should be re-started (
True) or not (
False) at the end of the evaluation. If
restart_stream=True it means that after the evaluation the model instance will remain in the last status from the evaluation. You can either continue treaining or use it only to get predictions. That is up to you to define (and code). However, as mentioned earlier,
EvaluatePrequential always performs both tessting and training.
@jacobmontiel Hi Jacob, I had another problem. I wanted to predict all the target values in 20 time steps after time t, and when I used EvaluatePrequentia, the parameters in it didn't seem to do the job.I can only do this by changing the source code? I hope you can give me some help with this problem. Thank you
This is not currently supported by the
EvaluatePrequential, we are working on a new feature for this case, but it might take some time until it is available. In the meantime the best option is, as you mention, to manually implement it. You can take a look into PR #222 for reference :-)
from skmultiflow.data import FileStream stream = FileStream("./src/skmultiflow/data/datasets/covtype.csv") stream.prepare_for_use() stream.n_classes # Output: 7 stream.target_values # Output: [1, 2, 3, 4, 5, 6, 7]