CogComp/saul

Load models

Opened this issue · 5 comments

It seems in all of out tests the models are loaded from jar files. I was trying to read form my locally trained models but I am not sure how the path should be set, it is not working.

if you don't specify the path it will load the locally trained models.

it simply does not work for me, could you check any of these options I have or commented out in the link below? I thought now we should use ClassifiersUtils for loading models but at least for this example it does not work, even when I give '/models` as path or without specifying path. @bhargav 2cd6e5e#diff-0ff94b549b4b5b02d866c30adfe4bba6R22

I looked at the SentimentApp.scala file and it seems that sentimentClassifier is never saved. The save function is called for SpamClassifier. @kordjamshidi Updating to sentimentClassifier.save() saves the model and sentimentClassifier.load() load the model fine.

But we have a problem in the ClassifierUtils were ClassifierUtils.LoadClassifier() without model path does not default to the default model path.

Yes, right but the models for me were already in models directory, when I was running it. The problem is that save() stores them in /saul/saul-examples/models and when we do not use save there are models in /saul/models, we certainly need a fix here. It is very confusing. We lack tests that use load directly without reading from model .jar files.