Examples of AlignedEdgeFilter


Examples of opennlp.ccg.disjunctivizer.AlignedEdgeFilter

    indices = new HashSet<Integer>();
    indices.add(0);
    indices.add(2);
    indices.add(3);
   
    filter = new AlignedEdgeFilter(indices, MatchType.SOURCE_ALIGNED, MatchType.TARGET_UNALIGNED);
  }
View Full Code Here

Examples of opennlp.ccg.disjunctivizer.AlignedEdgeFilter

  }
 
  @Test
  public void testAlignedEdgeFilter() {
    try {
      new AlignedEdgeFilter(null, MatchType.SOURCE_ALIGNED);
      fail("able to specify null alignment indices");
    }
    catch(IllegalArgumentException expected) {
      // do nothing
    }
View Full Code Here

Examples of opennlp.ccg.disjunctivizer.AlignedEdgeFilter

    filter.setAlignmentIndices(Collections.EMPTY_SET);
    assertFalse(filter.allows(one));
    assertFalse(filter.allows(two));
   
    // make self-contradictory filter
    filter = new AlignedEdgeFilter(indices, MatchType.SOURCE_ALIGNED, MatchType.SOURCE_UNALIGNED);
    assertFalse(filter.allows(one));
    assertFalse(filter.allows(two));
  }
View Full Code Here

Examples of opennlp.ccg.disjunctivizer.AlignedEdgeFilter

    indices.add(0);
    indices.add(2);
    indices.add(3);
   
    edgeFilter = new CompositeFilter<LFEdge>(new EdgeMatchFilter(one, MatchType.SOURCE_PREDICATE_MATCH,
        MatchType.LABEL_MISMATCH), new AlignedEdgeFilter(indices,
            MatchType.TARGET_ALIGNED, MatchType.SOURCE_ALIGNED));
   
    set = new FilteredLFEdgeSet(edges, edgeFilter);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.