Debian Codegraph @

seagen/filterESTsimple.C

raw symbols SCIP
1 #cxx . . $ `<file>/seagen/filterESTsimple.C`/include <stdio.h>
2 #include <stdlib.h>
3 #include <unistd.h>
4 #include <string.h>
5 #include <errno.h>
6 #include "aHit.H"cxx . . $ `<file>/seagen/aHit.H`/
7
8 // A very simple filter.
9 //
10 // Output the top 50 hits or all hits above 0.2, whichever is _smaller_.
11
12 #include "hitReader.H"cxx . . $ `<file>/seagen/hitReader.H`/
13
14 #define UNIQ_THRESHcxx . . $ `seagen/filterESTsimple.C:14:9`! 50
15 #define QUAL_THRESHcxx . . $ `seagen/filterESTsimple.C:15:9`! 0.2
16
17 int
18 maincxx . . $ main(afcd3168fc1188a4).(int argc, char **argv) {
19
20 if (argc == 1) {
21 fprintf(stderrcxx . . $ `<external>/232824719582829767/stdio.h:155:9`!, "ESTmapper utility function -- not for human use.\n");
22 exitcxx . . $ exit(44ed87f96534fad7).(1);
23 }
24
25 hitReadercxx . . $ hitReader# HRcxx . . $ hitReader#hitReader(d4f767463ce0a6b3).(argc);
26
27 // takes no args
28
29 int arg = 1;
30 while (arg < argc) {
31 HR.addInputFilecxx . . $ hitReader#addInputFile(fda57c8427c60377).(argv[arg]);
32 arg++;
33 }
34
35 while (HR.loadHitscxx . . $ hitReader#loadHits(c9857a73d68e59ba).()) {
36
37 HR.sortByCoveragecxx . . $ hitReader#sortByCoverage(49f6e7a06ebc5aa8).();
38
39 // Output top 'UNIQ_THRESH' hits
40
41 uint32cxx . . $ uint32# max = UNIQ_THRESHcxx . . $ `seagen/filterESTsimple.C:14:9`!;
42
43 if (max >= HR.numHitscxx . . $ hitReader#numHits(db52760e79bf9054).())
44 max = HR.numHitscxx . . $ hitReader#numHits(db52760e79bf9054).();
45
46 for (uint32cxx . . $ uint32# i=0; i<max; i++)
47 ahit_printASCIIcxx . . $ ahit_printASCII(6c917abaf95665ca).(&HR[cxx . . $ hitReader#`operator[]`(38191595156c9293).i].acxx . . $ $anonymous_type_cf7e7b12f763008e_1#a., stdoutcxx . . $ `<external>/232824719582829767/stdio.h:154:9`!);
48
49 #if 0
50 uint32 count = 0;
51
52 for (uint32 i=0; i < HR.numHits(); i++)
53 if (QUAL_THRESH <= HR[i].coverage)
54 count++;
55
56 if ((count > 0) && (count < UNIQ_THRESH)) {
57 // Output all hits above QUAL_THRESH
58 for (uint32 i=0; i < HR.numHits(); i++)
59 if (QUAL_THRESH <= HR[i].coverage)
60 ahit_printASCII(&HR[i].a, stdout);
61 } else {
62 // Output top 'UNIQ_THRESH' hits
63 for (uint32 i=0; i < UNIQ_THRESH; i++)
64 ahit_printASCII(&HR[i].a, stdout);
65 }
66 #endif
67
68 }
69
70 return(0);
71 }