git-svn-id: http://svn.tuebingen.mpg.de/ag-raetsch/projects/QPalma@8673 e1793c9e...
authorraetsch <raetsch@e1793c9e-67f9-0310-80fc-b846ff1f7b36>
Fri, 18 Apr 2008 12:13:38 +0000 (12:13 +0000)
committerraetsch <raetsch@e1793c9e-67f9-0310-80fc-b846ff1f7b36>
Fri, 18 Apr 2008 12:13:38 +0000 (12:13 +0000)
scripts/PipelineHeuristic.py

index c593762..3686991 100644 (file)
@@ -221,19 +221,20 @@ class PipelineHeuristic:
 
             currentVMatchAlignment = dna, exons, est, original_est, quality,\
             currentAcc, currentDon
-            vMatchScore = self.calcAlignmentScore(currentVMatchAlignment)
 
             alternativeAlignmentScores = self.calcAlternativeAlignments(location)
 
-            start = cpu()
-            # found no alternatives
-            #if alternativeAlignmentScores == []:
-            #   continue
-            
             if alternativeAlignmentScores == []:
+                # no alignment necessary
                 maxAlternativeAlignmentScore = -inf
+                vMatchScore = 0.0 
             else:
                 maxAlternativeAlignmentScore = max(alternativeAlignmentScores)
+                # compute alignment for vmatch unspliced read
+                vMatchScore = self.calcAlignmentScore(currentVMatchAlignment)
+
+            start = cpu()
+            
             #print 'vMatchScore/alternativeScore: %f %f ' % (vMatchScore,maxAlternativeAlignmentScore)
             #print 'all candidates %s' % str(alternativeAlignmentScores)
 
@@ -567,9 +568,9 @@ if __name__ == '__main__':
    jp = os.path.join
 
    run_fname   = jp(dir,'run_object.pickle')
-   #data_fname = '/fml/ag-raetsch/share/projects/qpalma/solexa/current_data/map.vm_unspliced_1k'
+   data_fname = '/fml/ag-raetsch/share/projects/qpalma/solexa/current_data/map.vm_unspliced_1k'
 
-   data_fname  = '/fml/ag-raetsch/share/projects/qpalma/solexa/pipeline_data/map.vm_2k'
+   #data_fname  = '/fml/ag-raetsch/share/projects/qpalma/solexa/pipeline_data/map.vm_2k'
    #data_fname  = '/fml/ag-raetsch/share/projects/qpalma/solexa/pipeline_data/map.vm_100'
 
    param_fname = jp(dir,'param_500.pickle')