Machine Learning/moa: Difference between revisions
Jump to navigation
Jump to search
ThomasLotze (talk | contribs) (Starting to create a moa page, to be linked in from Machine learning when ready) |
ThomasLotze (talk | contribs) |
||
Line 8: | Line 8: | ||
==Training MOA models== | ==Training MOA models== | ||
* Your data will need to be in [http://www.cs.waikato.ac.nz/~ml/weka/arff.html ARFF format] | |||
* To evaluate the performance of different models, you can run varying prequential classifiers and look at their performance; for example, | |||
java -cp .:moa.jar:weka.jar -javaagent:sizeofag.jar moa.DoTask "EvaluatePrequential -l NaiveBayes -s (ArffFileStream -f atrain.arff -c -1) -O amodel_bayes.moa" | |||
java -cp .:moa.jar:weka.jar -javaagent:sizeofag.jar moa.DoTask "EvaluatePrequential -l HoeffdingTree -s (ArffFileStream -f atrain.arff -c -1) -O amodel_hoeffding.moa" | |||
* To actually generate the final model, you can run a command line like the following: | |||
java -cp .:moa.jar:weka.jar -javaagent:sizeofag.jar moa.DoTask "LearnModel -l NaiveBayes -s (ArffFileStream -f atrain.arff -c -1) -O amodel_bayes.moa" | |||
==Generating MOA model predictions== | ==Generating MOA model predictions== |
Revision as of 17:30, 6 June 2010
Setup Instructions
- Create a directory to run your moa programs from; we'll assume it is ~/moa
- Download the moa release .tar.gz file from http://sourceforge.net/projects/moa-datastream/ and extract it
- copy moa.jar into ~/moa
- Download the weka release .zip file from http://sourceforge.net/projects/weka/ and extract it
- copy weka.jar into ~/moa
- Download http://jroller.com/resources/m/maxim/sizeofag.jar and copy it into ~/moa
Training MOA models
- Your data will need to be in ARFF format
- To evaluate the performance of different models, you can run varying prequential classifiers and look at their performance; for example,
java -cp .:moa.jar:weka.jar -javaagent:sizeofag.jar moa.DoTask "EvaluatePrequential -l NaiveBayes -s (ArffFileStream -f atrain.arff -c -1) -O amodel_bayes.moa" java -cp .:moa.jar:weka.jar -javaagent:sizeofag.jar moa.DoTask "EvaluatePrequential -l HoeffdingTree -s (ArffFileStream -f atrain.arff -c -1) -O amodel_hoeffding.moa"
- To actually generate the final model, you can run a command line like the following:
java -cp .:moa.jar:weka.jar -javaagent:sizeofag.jar moa.DoTask "LearnModel -l NaiveBayes -s (ArffFileStream -f atrain.arff -c -1) -O amodel_bayes.moa"
Generating MOA model predictions
Other Resources
- MOA site: http://www.cs.waikato.ac.nz/~abifet/MOA/