private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
private static LabelVector[] getLabelVectorsFromClassifications (Classification[] c) { LabelVector[] ret = new LabelVector[c.length]; for (int i = 0; i < c.length; i++) ret[i] = c[i].getLabelVector(); return ret; }
public final int compare (Object a, Object b) { LabelVector x = (LabelVector) (((Classification)a).getLabelVector()); LabelVector y = (LabelVector) (((Classification)b).getLabelVector()); double difference = x.getBestValue() - y.getBestValue(); int toReturn = 0; if(difference > 0) toReturn = 1; else if (difference < 0) toReturn = -1; return(toReturn); }
public final int compare (Object a, Object b) { LabelVector x = (LabelVector) (((Classification)a).getLabelVector()); LabelVector y = (LabelVector) (((Classification)b).getLabelVector()); double difference = x.getBestValue() - y.getBestValue(); int toReturn = 0; if(difference > 0) toReturn = 1; else if (difference < 0) toReturn = -1; return(toReturn); }
public final int compare (Object a, Object b) { LabelVector x = (LabelVector) (((Classification)a).getLabelVector()); LabelVector y = (LabelVector) (((Classification)b).getLabelVector()); double difference = x.getBestValue() - y.getBestValue(); int toReturn = 0; if(difference > 0) toReturn = 1; else if (difference < 0) toReturn = -1; return(toReturn); }
/** Calculates the confidence in the tagging of a {@link Segment}. */ public double estimateConfidenceFor (Segment segment, SumLatticeDefault cachedLattice) { Classification c = this.meClassifier.classify (pipe.instanceFrom(new Instance ( segment, segment.getTruth(), null, null))); return c.getLabelVector().value (this.correct); } }
/** Calculates the confidence in the tagging of an {@link Instance}. */ public double estimateConfidenceFor (Instance instance, Object[] startTags, Object[] inTags) { Classification c = null; if (Alphabet.alphabetsMatch(instance, this.pipe)) c = this.meClassifier.classify (new SequenceConfidenceInstance (instance)); else c = this.meClassifier.classify (instance); return c.getLabelVector().value (this.correct); }
/** Calculates the confidence in the tagging of an {@link Instance}. */ public double estimateConfidenceFor (Instance instance, Object[] startTags, Object[] inTags) { Classification c = null; if (Alphabet.alphabetsMatch(instance, this.pipe)) c = this.meClassifier.classify (new SequenceConfidenceInstance (instance)); else c = this.meClassifier.classify (instance); return c.getLabelVector().value (this.correct); }
/** Calculates the confidence in the tagging of a {@link Segment}. */ public double estimateConfidenceFor (Segment segment, SumLatticeDefault cachedLattice) { Classification c = this.meClassifier.classify (pipe.instanceFrom(new Instance ( segment, segment.getTruth(), null, null))); return c.getLabelVector().value (this.correct); } }
/** Calculates the confidence in the tagging of a {@link Segment}. */ public double estimateConfidenceFor (Segment segment, SumLatticeDefault cachedLattice) { Classification c = this.meClassifier.classify (pipe.instanceFrom(new Instance ( segment, segment.getTruth(), null, null))); return c.getLabelVector().value (this.correct); } }
private double getScore (AgglomerativeNeighbor pwneighbor) { if (scoreCache == null) scoreCache = new PairwiseMatrix(pwneighbor.getOriginal().getNumInstances()); int[] indices = pwneighbor.getNewCluster(); if (scoreCache.get(indices[0], indices[1]) == 0.0) { scoreCache.set(indices[0], indices[1], classifier.classify(pwneighbor).getLabelVector().value(scoringLabel)); } return scoreCache.get(indices[0], indices[1]); }
private double getScore (AgglomerativeNeighbor pwneighbor) { if (scoreCache == null) scoreCache = new PairwiseMatrix(pwneighbor.getOriginal().getNumInstances()); int[] indices = pwneighbor.getNewCluster(); if (scoreCache.get(indices[0], indices[1]) == 0.0) { scoreCache.set(indices[0], indices[1], classifier.classify(pwneighbor).getLabelVector().value(scoringLabel)); } return scoreCache.get(indices[0], indices[1]); }
private double getScore (AgglomerativeNeighbor pwneighbor) { if (scoreCache == null) scoreCache = new PairwiseMatrix(pwneighbor.getOriginal().getNumInstances()); int[] indices = pwneighbor.getNewCluster(); if (scoreCache.get(indices[0], indices[1]) == 0.0) { scoreCache.set(indices[0], indices[1], classifier.classify(pwneighbor).getLabelVector().value(scoringLabel)); } return scoreCache.get(indices[0], indices[1]); }
private double getScore (AgglomerativeNeighbor pwneighbor) { if (scoreCache == null) scoreCache = new PairwiseMatrix(pwneighbor.getOriginal().getNumInstances()); int[] indices = pwneighbor.getNewCluster(); if (scoreCache.get(indices[0], indices[1]) == 0.0) { scoreCache.set(indices[0], indices[1], classifier.classify(pwneighbor).getLabelVector().value(scoringLabel)); } return scoreCache.get(indices[0], indices[1]); }