Example usage for org.apache.mahout.classifier.naivebayes BayesUtils readIndexFromCache

List of usage examples for org.apache.mahout.classifier.naivebayes BayesUtils readIndexFromCache

Introduction

In this page you can find the example usage for org.apache.mahout.classifier.naivebayes BayesUtils readIndexFromCache.

Prototype

public static OpenObjectIntHashMap<String> readIndexFromCache(Configuration conf) throws IOException 

Source Link

Usage

From source file:com.netease.news.classifier.naivebayes.IndexInstancesMapper.java

License:Apache License

@Override
protected void setup(Context ctx) throws IOException, InterruptedException {
    super.setup(ctx);
    labelIndex = BayesUtils.readIndexFromCache(ctx.getConfiguration());
}