OK I'm trying to use Mallet to classify some documents in Windows
I've achieved it in Linux. Just can't get it do the job in Windows (target environment)
I've imported the data into a .mallet file.
And then created a classifier using this input data.
-rw-r--r-- 1 henry henry 15197116 Feb 23 15:56 nntp.classifier
and
07/03/2014 21:28 15,197,116 nntp.classifier
However when I run in Linux:
bin/mallet classify-dir --input ./testfolder --output - --classifier nntp.classifier
it iterates any files in the testfolder and dumps out what class it thinks each it.
But if I run same command in Windows:
bin\mallet classify-dir --input ./testfolder --output - --classifier nntp.classifier
It just dumps out the command list:
Mallet 2.0 commands:
import-dir load the contents of a directory into mallet instances (one per file)
import-file load a single file into mallet instances (one per line)
import-svmlight load a single SVMLight format data file into mallet instances (one per line)
train-classifier train a classifier from Mallet data files
train-topics train a topic model from Mallet data files
infer-topics use a trained topic model to infer topics for new documents
estimate-topics estimate the probability of new documents given a trained model
hlda train a topic model using Hierarchical LDA
prune remove features based on frequency or information gain
split divide data into testing, training, and validation portions
Include --help with any option for more information
Something that I did notice: I
f I run bin/mallet classify-dir --help
in linux I get the help file i.e. descriptions of each command, but the same thing in Windows bin\mallet classify-dir --help
does not produce the same result - just that command list above... (it does the same thing if you enter junk as the command)
Whereas one of the earlier command e.g. bin/mallet import-dir --help
and bin\mallet import-dir --help
produces the same full help file output.