public class LabelIndexer extends Object
| Modifier and Type | Field and Description |
|---|---|
com.google.common.collect.BiMap<String,Integer> |
labelIndexer |
| Constructor and Description |
|---|
LabelIndexer(List<Tuple> trainingData) |
| Modifier and Type | Method and Description |
|---|---|
Map<String,Double> |
convertMapKey(Map<Integer,Double> probs) |
int |
getIndex(String label) |
Set<Integer> |
getIndexSet() |
String |
getLabel(int index) |
int |
getLabelSize() |
boolean |
hasLabel(String label) |
void |
putByLabels(List<String> labels) |
void |
readFromSerializedString(String str) |
String |
serializeToString() |
public int getIndex(String label)
public String getLabel(int index)
public boolean hasLabel(String label)
public int getLabelSize()
public String serializeToString()
public void readFromSerializedString(String str)
Copyright © 2017. All rights reserved.