Package statechum.analysis.learning.rpnicore.Transform

Examples of statechum.analysis.learning.rpnicore.Transform.ConvertALabel


 
  /** Creates a label from the string of text and a configuration. */
  public static void createLabel(String str, Configuration config)
  {
    ConvertALabel converter = null;
    AbstractLearnerGraph.generateNewLabel("{"+ErlangLabel.missingFunction+","+str+"}", config,converter);
  }
View Full Code Here


 
  public static void runExperiment(@SuppressWarnings("unused") String args[]) throws Exception
  {
    Configuration config = Configuration.getDefaultConfiguration().copy();config.setAskQuestions(false);config.setDebugMode(false);config.setGdLowToHighRatio(0.7);config.setRandomPathAttemptFudgeThreshold(1000);
    config.setTransitionMatrixImplType(STATETREE.STATETREE_ARRAY);config.setLearnerScoreMode(ScoreMode.GENERAL);
    ConvertALabel converter = new Transform.InternStringLabel();
    GlobalConfiguration.getConfiguration().setProperty(G_PROPERTIES.LINEARWARNINGS, "false");
    final int chunkSize = 3;
 
    final int ThreadNumber = ExperimentRunner.getCpuNumber()
    ExecutorService executorService = Executors.newFixedThreadPool(ThreadNumber);
View Full Code Here

  public static void runExperiment() throws Exception
  {
    DrawGraphs gr = new DrawGraphs();
    Configuration config = Configuration.getDefaultConfiguration().copy();config.setAskQuestions(false);config.setDebugMode(false);config.setGdLowToHighRatio(0.7);config.setRandomPathAttemptFudgeThreshold(1000);
    config.setTransitionMatrixImplType(STATETREE.STATETREE_ARRAY);config.setLearnerScoreMode(ScoreMode.ONLYOVERRIDE);
    ConvertALabel converter = new Transform.InternStringLabel();
    GlobalConfiguration.getConfiguration().setProperty(G_PROPERTIES.LINEARWARNINGS, "false");
    final int ThreadNumber = ExperimentRunner.getCpuNumber()
    ExecutorService executorService = Executors.newFixedThreadPool(ThreadNumber);
    final int minStateNumber = 20;
    final int samplesPerFSM = 10;
View Full Code Here

  public static void runExperiment() throws Exception
  {
    DrawGraphs gr = new DrawGraphs();
    Configuration config = Configuration.getDefaultConfiguration().copy();config.setAskQuestions(false);config.setDebugMode(false);config.setGdLowToHighRatio(0.7);config.setRandomPathAttemptFudgeThreshold(1000);
    config.setTransitionMatrixImplType(STATETREE.STATETREE_LINKEDHASH);config.setLearnerScoreMode(ScoreMode.COMPATIBILITY);//ONLYOVERRIDE);
    ConvertALabel converter = new Transform.InternStringLabel();
    GlobalConfiguration.getConfiguration().setProperty(G_PROPERTIES.LINEARWARNINGS, "false");
    final int ThreadNumber = ExperimentRunner.getCpuNumber()
    ExecutorService executorService = Executors.newFixedThreadPool(ThreadNumber);
    final int minStateNumber = 20;
    final int samplesPerFSM = 10;
View Full Code Here

  {
    Writer randomFSM = null;
    try
    {
      Configuration config = Configuration.getDefaultConfiguration().copy();
      ConvertALabel converter = null;
      int initStates = 25, graphComplexityMax=6, experimentsPerCategory = 100;
      for(int graphComplexity=0;graphComplexity < graphComplexityMax;graphComplexity++)
      {
        int states=initStates+graphComplexity*20;
        int alphabet = states/2;
View Full Code Here

  public static void runExperiment(String args[]) throws Exception
  {
    Configuration config = Configuration.getDefaultConfiguration().copy();config.setAskQuestions(false);config.setDebugMode(false);config.setGdLowToHighRatio(0.7);config.setRandomPathAttemptFudgeThreshold(1000);
    config.setGdFailOnDuplicateNames(false);
    config.setTransitionMatrixImplType(STATETREE.STATETREE_ARRAY);config.setLearnerScoreMode(ScoreMode.GENERAL);
    ConvertALabel converter = new Transform.InternStringLabel();
    GlobalConfiguration.getConfiguration().setProperty(G_PROPERTIES.LINEARWARNINGS, "false");
    final int chunkSize = 3;
 
    // Inference from a few traces
    RunSubExperiment<ThreadResult> experimentRunner = new RunSubExperiment<PairQualityLearner.ThreadResult>(ExperimentRunner.getCpuNumber(),"data",args);
View Full Code Here

  public static void runExperiment() throws Exception
  {
    DrawGraphs gr = new DrawGraphs();
    Configuration config = Configuration.getDefaultConfiguration().copy();config.setAskQuestions(false);config.setDebugMode(false);config.setGdLowToHighRatio(0.7);config.setRandomPathAttemptFudgeThreshold(1000);
    config.setTransitionMatrixImplType(STATETREE.STATETREE_LINKEDHASH);
    ConvertALabel converter = new Transform.InternStringLabel();
    //gr_NewToOrig.setLimit(7000);
    GlobalConfiguration.getConfiguration().setProperty(G_PROPERTIES.LINEARWARNINGS, "false");
    final int ThreadNumber = ExperimentRunner.getCpuNumber();
   
    ExecutorService executorService = Executors.newFixedThreadPool(ThreadNumber);
View Full Code Here

  public static void runExperiment() throws Exception
  {
    DrawGraphs gr = new DrawGraphs();
    Configuration config = Configuration.getDefaultConfiguration().copy();config.setAskQuestions(false);config.setDebugMode(false);config.setGdLowToHighRatio(0.7);config.setRandomPathAttemptFudgeThreshold(1000);
    config.setTransitionMatrixImplType(STATETREE.STATETREE_LINKEDHASH);config.setLearnerScoreMode(ScoreMode.COMPATIBILITY);
    ConvertALabel converter = new Transform.InternStringLabel();
    GlobalConfiguration.getConfiguration().setProperty(G_PROPERTIES.LINEARWARNINGS, "false");
    final int ThreadNumber = ExperimentRunner.getCpuNumber()
    ExecutorService executorService = Executors.newFixedThreadPool(ThreadNumber);
    final int minStateNumber = 20;
    final int samplesPerFSM = 10;
View Full Code Here

      });
    }

    public static <TARGET_TYPE,CACHE_TYPE extends CachedData<TARGET_TYPE,CACHE_TYPE>> void convertLabelsToStrings(AbstractLearnerGraph<TARGET_TYPE,CACHE_TYPE> grFrom, AbstractLearnerGraph<TARGET_TYPE,CACHE_TYPE> grTo)
    {
        AbstractLearnerGraph.interpretLabelsOnGraph(grFrom,grTo,new Transform.ConvertLabel(new ConvertALabel() {
       
        @Override
        public Label convertLabelToLabel(Label label) {
          ErlangLabel lbl = (ErlangLabel)label;
          return new StringLabel(lbl.function.getName()+"/"+lbl.function.getArity()+","+lbl.input+","+lbl.expectedOutput);
View Full Code Here

    public OtpErlangObject computeBCR_and_structuralDifference(LearnerGraph referenceGraph, LearnerGraph learntGraph, Configuration config)
    {
      final int chunkLen = 3;
     
      ConvertALabel converter = new Transform.InternStringLabel();
      LearnerEvaluationConfiguration learnerEval = new LearnerEvaluationConfiguration(config);learnerEval.setLabelConverter(converter);
      int states = referenceGraph.getAcceptStateNumber();
      final Collection<List<Label>> testSet = PaperUAS.computeEvaluationSet(referenceGraph,states*3,PairQualityLearner.makeEven(states*referenceGraph.pathroutines.computeAlphabet().size()));
     
      DifferenceToReferenceDiff differenceStructural=DifferenceToReferenceDiff.estimationOfDifferenceDiffMeasure(referenceGraph, learntGraph, config, 1);
View Full Code Here

TOP

Related Classes of statechum.analysis.learning.rpnicore.Transform.ConvertALabel

Copyright © 2018 www.massapicom. 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.