Package statechum.model.testset.PTASequenceEngine

Examples of statechum.model.testset.PTASequenceEngine.SequenceSet.cross()


 
  public static PosNegPrecisionRecall compare(LearnerGraph specfsm, LearnerGraph imp){
    PTA_computePrecisionRecall precRec = new PTA_computePrecisionRecall(imp);
    PTASequenceEngine engine = new PTA_FSMStructure(specfsm);
    SequenceSet partialPTA = engine.new SequenceSet();partialPTA.setIdentity();
    partialPTA = partialPTA.cross(specfsm.wmethod.getFullTestSet(1));
    return precRec.crossWith(engine);
  }
 
  public static PosNegPrecisionRecall compare(Collection<List<String>> tests, LearnerGraph specfsm, LearnerGraph imp){
    PTA_computePrecisionRecall precRec = new PTA_computePrecisionRecall(imp);
View Full Code Here


 
  public static PosNegPrecisionRecall compare(Collection<List<String>> tests, LearnerGraph specfsm, LearnerGraph imp){
    PTA_computePrecisionRecall precRec = new PTA_computePrecisionRecall(imp);
    PTASequenceEngine engine = new PTA_FSMStructure(specfsm);
    SequenceSet partialPTA = engine.new SequenceSet();partialPTA.setIdentity();
    partialPTA = partialPTA.cross(tests);
    return precRec.crossWith(engine);
  }
 
  private static void printTests(Collection<List<String>> tests){
    for (List<String> list : tests) {
View Full Code Here

            }
           
          });
        }
      };
      SequenceSet minusInit = sOrigMinus.new SequenceSet();minusInit.setIdentity();minusInit.cross(minusTrainingSet);
      int totalLenOrig = 0, origNumber=0;
      for(List<String> seq:minusTrainingSet)
      {
        assert seq.size() > 1;
        assert graph.getVertex(seq) == null;// the seq is negative indeed
View Full Code Here

      learnt = learn(recorder,sMinus);
      //learned = new LearnerGraph(config);
     
      PTASequenceEngine testSetEngine = new PTA_FSMStructure(graph);
      SequenceSet ptaTestSet = testSetEngine.new SequenceSet();ptaTestSet.setIdentity();
      ptaTestSet.cross(graphTestSet);

      PTA_computePrecisionRecall precRec = new PTA_computePrecisionRecall(learnt);
     
      PosNegPrecisionRecall ptaPR = precRec.crossWith(sMinus);
      PosNegPrecisionRecall prNeg = precRec.crossWith(testSetEngine);
View Full Code Here

    characterisationSet = computeWSet_reducedmemory(coregraph);if (characterisationSet.isEmpty()) characterisationSet.add(Arrays.asList(new String[]{}));
    transitionCover = crossWithSet(stateCover,alphabet);transitionCover.addAll(stateCover);

    PTASequenceEngine engine = new PTA_FSMStructure(coregraph);
    SequenceSet partialPTA = engine.new SequenceSet();partialPTA.setIdentity();
    partialPTA = partialPTA.cross(stateCover);
   
    partialPTA.cross(characterisationSet);
    for(int i=0;i<=numberOfExtraStates;i++)
    {
      partialPTA = partialPTA.crossWithSet(alphabet);
View Full Code Here

    PTASequenceEngine engine = new PTA_FSMStructure(coregraph);
    SequenceSet partialPTA = engine.new SequenceSet();partialPTA.setIdentity();
    partialPTA = partialPTA.cross(stateCover);
   
    partialPTA.cross(characterisationSet);
    for(int i=0;i<=numberOfExtraStates;i++)
    {
      partialPTA = partialPTA.crossWithSet(alphabet);
      partialPTA.cross(characterisationSet);
    }
View Full Code Here

   
    partialPTA.cross(characterisationSet);
    for(int i=0;i<=numberOfExtraStates;i++)
    {
      partialPTA = partialPTA.crossWithSet(alphabet);
      partialPTA.cross(characterisationSet);
    }
   
    return engine.getData();
  }
View Full Code Here

    ));
    SequenceSet seqStart2 = en.new SequenceSet();seqStart2.crossWithSequence(labelList(
        new String[] {"t"}
    ));
    SequenceSet seqDifferent1 = en.new SequenceSet();seqDifferent1.setIdentity();
    SequenceSet seqDifferent2 = en.new SequenceSet();seqDifferent2.setIdentity();seqDifferent2.cross(TestFSMAlgo.buildList(new String[][] {
        new String[] {"a"}
       
    },mainConfiguration,converter));
    equalityTestingHelper(seqStart1,seqStart2,seqDifferent1,seqDifferent2, true);
  }
View Full Code Here

  /** Tests containsSequence. */
  @Test
  public final void test_containsSequence2()
  {
    SequenceSet seqStart = en.new SequenceSet();seqStart.setIdentity();
    seqStart.cross(TestFSMAlgo.buildList(new String[][] {
        new String[] {"a","a"},
        new String[] {"c"}
    },mainConfiguration,converter));
    assertTrue(en.containsSequence(labelList(new String[]{"c"})));
    assertTrue(en.containsAsLeaf(labelList(new String[]{"c"})));
View Full Code Here

  /** Tests extendsLeaf. */
  @Test
  public final void test_extendsLeaf2()
  {
    SequenceSet seqStart = engine_testLimitToGraph.new SequenceSet();seqStart.setIdentity();
    seqStart.cross(TestFSMAlgo.buildList(new String[][] {
        new String[] {"a","c","b"},
        new String[] {"c","c","c","c"}
    },mainConfiguration,converter));
   
    assertFalse(engine_testLimitToGraph.extendsLeaf(labelList(new String[]{})));
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.