Examples of findVertex()


Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-b->N ", "testKtails4",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
  @Test
  public final void testKtails5()
  {
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

  @Test
  public final void testKtails5()
  {
    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-c->P", "testKtails5",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

  @Test
  public final void testKtails5()
  {
    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-c->P", "testKtails5",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

  public final void testKtails5()
  {
    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-c->P", "testKtails5",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
  /** A match. */
 
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

  public final void testKtails5()
  {
    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-c->P", "testKtails5",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
  /** A match. */
 
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

  {
    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-c->P", "testKtails5",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
  /** A match. */
  @Test
 
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

  {
    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-c->P", "testKtails5",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
  /** A match. */
  @Test
 
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraph.findVertex()

    testConfig.setKlimit(2);
    LearnerGraph fsm = FsmParser.buildLearnerGraph("A-a->B-b->C-a->D-d->E / B-c->F-a->G-e->H / M-c->P", "testKtails5",testConfig,getLabelConverter());
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("M"),fsm.findVertex("B")), false));
    Assert.assertEquals(0,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), true));
    Assert.assertEquals(-1,fsm.pairscores.computeStateScoreKTails(new StatePair(fsm.findVertex("B"),fsm.findVertex("M")), false));
 
 
  /** A match. */
  @Test
  public final void testKtails6()
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraphND.findVertex()

    grA.transitionMatrix.put(disconnectedA1,grA.createNewRow());grA.transitionMatrix.put(disconnectedA2,grA.createNewRow());
    grB.transitionMatrix.put(disconnectedB2,grB.createNewRow());grB.transitionMatrix.put(disconnectedB3,grB.createNewRow());
   
    String [] expectedDuplicates = (stateC.equals("C"))? new String[]{ stateC,"A" }:new String[]{"A"};
    LearnerGraphND outcome = runTest(grA,grB, "D", expectedDuplicates);
    Assert.assertNull(outcome.findVertex(disconnectedA1));
    Assert.assertTrue(DeterministicDirectedSparseGraph.deepEquals(disconnectedB2, outcome.findVertex(disconnectedB2)));
    Assert.assertTrue(DeterministicDirectedSparseGraph.deepEquals(disconnectedB3, outcome.findVertex(disconnectedB3)));
  }
 
  /** Graph B is slightly different now, hence duplicates are different too. */
 
View Full Code Here

Examples of statechum.analysis.learning.rpnicore.LearnerGraphND.findVertex()

    grB.transitionMatrix.put(disconnectedB2,grB.createNewRow());grB.transitionMatrix.put(disconnectedB3,grB.createNewRow());
   
    String [] expectedDuplicates = (stateC.equals("C"))? new String[]{ stateC,"A" }:new String[]{"A"};
    LearnerGraphND outcome = runTest(grA,grB, "D", expectedDuplicates);
    Assert.assertNull(outcome.findVertex(disconnectedA1));
    Assert.assertTrue(DeterministicDirectedSparseGraph.deepEquals(disconnectedB2, outcome.findVertex(disconnectedB2)));
    Assert.assertTrue(DeterministicDirectedSparseGraph.deepEquals(disconnectedB3, outcome.findVertex(disconnectedB3)));
  }
 
  /** Graph B is slightly different now, hence duplicates are different too. */
  @Test
 
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.