|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sourceforge.nite.datainspection.timespan.SegmentAligner
public class SegmentAligner
Aligns two 'segment annotations'. See design on paper for documentation
Constructor Summary | |
---|---|
SegmentAligner()
|
Method Summary | |
---|---|
static SegmentAlignment |
alignSegments(java.util.ArrayList segmentList1,
java.util.ArrayList segmentList2,
double th,
Predicate isIgnoreP)
This default alignment method takes two segments to be 'equal' if the difference in time is at most 'th'. |
static java.util.ArrayList |
createFinalMatching(java.util.ArrayList candidates,
java.util.Set unmatched1,
java.util.Set unmatched2)
recursive: make one heaviest match final, then split in left and right and do again method taken from {kuper2004,IJCAI, MUMIS merging} candidatematching lists are sorted on weight! but final matching list will automatically be sorted on time! also modifies the unmatchedSegmentLists... |
static WeightedPair |
getCandidate(NOMWriteElement nwe1,
NOMWriteElement nwe2,
double th,
Predicate isIgnoreP)
Given two segments from different coders, return null if they cannot be aligned (e.g. |
static void |
selectFinalMatchings(SegmentAlignment data,
java.util.ArrayList candidateMatchings)
Use a derivation of the MUMIS merging algorithm to select final alignments between segments of different annotators. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SegmentAligner()
Method Detail |
---|
public static SegmentAlignment alignSegments(java.util.ArrayList segmentList1, java.util.ArrayList segmentList2, double th, Predicate isIgnoreP)
public static WeightedPair getCandidate(NOMWriteElement nwe1, NOMWriteElement nwe2, double th, Predicate isIgnoreP)
If the timing constraints are met, the pair is a candidate for alignment. The WEIGHT of the alignments is calculated based on timing difference
NOT APPLIED YET is the following extension. (see also package documentation) as a special case, the elements should be 'very large'. In the last case there should be a large /overlap/ between the segments. (The rationale is that if segments are 20 seconds long, then a delay of 2 seconds is not as bad as long as the /overlap/ between the segments is e.g. 15 seconds). 'Large enough': overlap divided by sum of lengths should be .25 or larger ( they overlap for more than half (equalsized) or e.g. one is no more than 3 times size of other (unequalsized containment))
NOT APPLIED YET is the following extension. (see also package documentation) WEIGHT is also determined by the labelling difference as calculated by the DistanceMetric from the constructor.
public static void selectFinalMatchings(SegmentAlignment data, java.util.ArrayList candidateMatchings)
public static java.util.ArrayList createFinalMatching(java.util.ArrayList candidates, java.util.Set unmatched1, java.util.Set unmatched2)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |