Ignore:
Timestamp:
05/29/14 22:43:07 (10 years ago)
Author:
rkrimmel
Message:

new Smith waterman variant

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ralph/src/main/java/de/ugoe/cs/autoquest/tasktrees/temporalrelation/SequenceForTaskDetectionRuleAlignment.java

    r1557 r1558  
    2828import de.ugoe.cs.autoquest.tasktrees.alignment.algorithms.NumberSequence; 
    2929import de.ugoe.cs.autoquest.tasktrees.alignment.algorithms.SmithWaterman; 
     30import de.ugoe.cs.autoquest.tasktrees.alignment.algorithms.SmithWatermanRepeated; 
    3031import de.ugoe.cs.autoquest.tasktrees.alignment.substitution.ObjectDistanceSubstitionMatrix; 
    3132import de.ugoe.cs.autoquest.tasktrees.taskequality.TaskEquality; 
     
    145146         
    146147         
    147          
    148148        // this is the real rule application. Loop while something is replaced. 
    149149        SymbolMap<ITaskInstance, ITask> uniqueTasks = harmonizeEventTaskInstancesModel(appData); 
    150         ObjectDistanceSubstitionMatrix submat = new ObjectDistanceSubstitionMatrix(uniqueTasks);   
     150        ObjectDistanceSubstitionMatrix submat = new ObjectDistanceSubstitionMatrix(uniqueTasks,20); 
    151151        submat.generate(); 
    152          
    153         SmithWaterman sw = new SmithWaterman(numberseqs.get(1).getSequence(), numberseqs.get(1).getSequence(), submat); 
    154          
     152       
     153        
     154         
     155        System.out.print("Sequence 1: "); 
     156        NumberSequence ns1 = numberseqs.get(7); 
     157        NumberSequence ns2 = numberseqs.get(8); 
     158        ns1.printSequence(); 
     159        System.out.print("Sequence 2: "); 
     160        ns2.printSequence(); 
     161        //SmithWatermanRepeated sw = new SmithWatermanRepeated(numberseqs.get(20).getSequence(), numberseqs.get(24).getSequence(), submat,10); 
     162        SmithWatermanRepeated sw = new SmithWatermanRepeated(ns1.getSequence(), ns2.getSequence(), submat,15); 
     163        System.out.println("Max Scrore: " + sw.getMaxScore()); 
     164         
     165        sw.printDPMatrix(); 
    155166    
    156167         
    157168         
    158        
    159          
    160          
    161         //Hier mein kram hin 
     169 
    162170        do { 
    163171            System.out.println(); 
     
    165173             
    166174             
    167             appData.getStopWatch().start("whole loop"); 
    168             detectAndReplaceIterations(appData); 
    169  
    170             appData.getStopWatch().start("task replacement"); 
    171             detectAndReplaceTasks(appData); 
    172             appData.getStopWatch().stop("task replacement"); 
    173             appData.getStopWatch().stop("whole loop"); 
    174              
    175              
    176             appData.getStopWatch().dumpStatistics(System.out); 
    177             appData.getStopWatch().reset(); 
     175            //appData.getStopWatch().start("whole loop"); 
     176            //detectAndReplaceIterations(appData); 
     177 
     178            //appData.getStopWatch().start("task replacement"); 
     179            //detectAndReplaceTasks(appData); 
     180            //appData.getStopWatch().stop("task replacement"); 
     181            //appData.getStopWatch().stop("whole loop"); 
     182             
     183             
     184            //appData.getStopWatch().dumpStatistics(System.out); 
     185            //appData.getStopWatch().reset(); 
    178186             
    179187        } 
Note: See TracChangeset for help on using the changeset viewer.