You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
how to solve this below: i am using latest Mallet-202108 downloaded here
C:\Users\4>mallet import-dir --input D:\test_mallet\input\ --output D:\test_mallet\data.mallet --keep-sequence --remove-stopwords
Labels =
D:\test_mallet\input
C:\Users\4>mallet train-classifier --input D:\test_mallet\data.mallet --output-classifier D:\test_mallet\my.classifier
Training portion = 1.0
Unlabeled training sub-portion = 0.0
Validation portion = 0.0
Testing portion = 0.0
-------------------- Trial 0 --------------------
Trial 0 Training NaiveBayesTrainer with 639 instances
Exception in thread "main" java.lang.ClassCastException: cc.mallet.types.FeatureSequence cannot be cast to cc.mallet.types.FeatureVector
at cc.mallet.classify.NaiveBayesTrainer.incorporateOneInstance(NaiveBayesTrainer.java:274)
at cc.mallet.classify.NaiveBayesTrainer.trainIncremental(NaiveBayesTrainer.java:202)
at cc.mallet.classify.NaiveBayesTrainer.train(NaiveBayesTrainer.java:191)
at cc.mallet.classify.NaiveBayesTrainer.train(NaiveBayesTrainer.java:57)
at cc.mallet.classify.tui.Vectors2Classify.main(Vectors2Classify.java:446)
C:\Users\4>
The text was updated successfully, but these errors were encountered:
how to solve this below: i am using latest Mallet-202108 downloaded here
C:\Users\4>mallet import-dir --input D:\test_mallet\input\ --output D:\test_mallet\data.mallet --keep-sequence --remove-stopwords
Labels =
D:\test_mallet\input
C:\Users\4>mallet train-classifier --input D:\test_mallet\data.mallet --output-classifier D:\test_mallet\my.classifier
Training portion = 1.0
Unlabeled training sub-portion = 0.0
Validation portion = 0.0
Testing portion = 0.0
-------------------- Trial 0 --------------------
Trial 0 Training NaiveBayesTrainer with 639 instances
Exception in thread "main" java.lang.ClassCastException: cc.mallet.types.FeatureSequence cannot be cast to cc.mallet.types.FeatureVector
at cc.mallet.classify.NaiveBayesTrainer.incorporateOneInstance(NaiveBayesTrainer.java:274)
at cc.mallet.classify.NaiveBayesTrainer.trainIncremental(NaiveBayesTrainer.java:202)
at cc.mallet.classify.NaiveBayesTrainer.train(NaiveBayesTrainer.java:191)
at cc.mallet.classify.NaiveBayesTrainer.train(NaiveBayesTrainer.java:57)
at cc.mallet.classify.tui.Vectors2Classify.main(Vectors2Classify.java:446)
C:\Users\4>
The text was updated successfully, but these errors were encountered: