NCBI C++ ToolKit
nw_spliced_aligner32.cpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id: nw_spliced_aligner32.cpp 100300 2023-07-18 19:57:36Z mozese2 $
2 * ===========================================================================
3 *
4 * PUBLIC DOMAIN NOTICE
5 * National Center for Biotechnology Information
6 *
7 * This software/database is a "United States Government Work" under the
8 * terms of the United States Copyright Act. It was written as part of
9 * the author's official duties as a United States Government employee and
10 * thus cannot be copyrighted. This software/database is freely available
11 * to the public for use. The National Library of Medicine and the U.S.
12 * Government have not placed any restriction on its use or reproduction.
13 *
14 * Although all reasonable efforts have been taken to ensure the accuracy
15 * and reliability of the software and data, the NLM and the U.S.
16 * Government do not and cannot warrant the performance or results that
17 * may be obtained by using this software or data. The NLM and the U.S.
18 * Government disclaim all warranties, express or implied, including
19 * warranties of performance, merchantability or fitness for any particular
20 * purpose.
21 *
22 * Please cite the author in any work or product based on this material.
23 *
24 * ===========================================================================
25 *
26 * Authors: Yuri Kapustin
27 *
28 * File Description: CSplicedAligner32
29 *
30 * ===========================================================================
31 *
32 */
33 
34 
35 #include <ncbi_pch.hpp>
36 #include "messages.hpp"
39 
41 
42 const unsigned char g_nwspl32_donor[splice_type_count_32][2] = {
43  {'G','T'}, // donor type 1 in CDonorAcceptorMatrix coding
44  {'G','C'}, // 2
45  {'A','T'} // 3
46 };
47 
48 const unsigned char g_nwspl32_acceptor[splice_type_count_32][2] = {
49  {'A','G'}, // 1
50  {'A','G'}, // 2
51  {'A','C'} // 3
52 };
53 
54 
55 // Transcript coding
56 // (lower bits contain jump value for gaps and introns)
57 const Uint4 kTypeDiag = 0x00000000; // single match or mismatch
58 const Uint4 kTypeGap = 0x40000000; // gap - any type
59 const Uint4 kTypeIntron = 0x80000000; // intron
60 
61 
62 // Donor-acceptor static object used
63 // to figure out what donors and aceptors
64 // could be transformed to any given na pair
65 // by mutating either of its characters (but not both).
66 // donor types: bits 5-7
67 // acceptor types: bits 1-3
68 
70 
71 public:
72 
74  memset(m_Matrix, 0, sizeof m_Matrix);
75  x_Set('A', 'A', 0x47); // 3 ; 1, 2, 3
76  x_Set('A', 'G', 0x47); // 3 ; 1, 2, 3
77  x_Set('A', 'T', 0x57); // 1, 3 ; 1, 2, 3
78  x_Set('A', 'C', 0x67); // 2, 3 ; 1, 2, 3
79  x_Set('G', 'A', 0x33); // 1, 2 ;
80  x_Set('G', 'G', 0x33); // 1, 2 ; 1, 2
81  x_Set('G', 'T', 0x70); // 1, 2, 3 ;
82  x_Set('G', 'C', 0x34); // 1, 2 ; 3
83  x_Set('T', 'A', 0x00); // ;
84  x_Set('T', 'G', 0x03); // ; 1, 2
85  x_Set('T', 'T', 0x50); // 1, 3 ;
86  x_Set('T', 'C', 0x24); // 2 ; 3
87  x_Set('C', 'A', 0x00); // ;
88  x_Set('C', 'G', 0x03); // ; 1, 2
89  x_Set('C', 'T', 0x50); // 1, 3 ;
90  x_Set('C', 'C', 0x24); // 2 ; 3
91  }
92 
93  const Uint1* GetMatrix() const {
94  return m_Matrix[0];
95  }
96 
97 private:
98 
99  void x_Set(char c1, char c2, Uint1 val) {
100  m_Matrix[(unsigned char)c1][(unsigned char)c2] = val;
101  }
102 
103  Uint1 m_Matrix [256][256];
104 
105 };
106 
107 
108 namespace {
109  CDonorAcceptorMatrix g_dnr_acc_matrix;
110 }
111 
113  m_Wd1(GetDefaultWd1()),
114  m_Wd2(GetDefaultWd2())
115 {
116  for(unsigned char st = 0; st < splice_type_count_32; ++st) {
117  m_Wi[st] = GetDefaultWi(st);
118  }
119 }
120 
121 CSplicedAligner32::CSplicedAligner32(const char* seq1, size_t len1,
122  const char* seq2, size_t len2)
123  : CSplicedAligner(seq1, len1, seq2, len2),
124  m_Wd1(GetDefaultWd1()),
125  m_Wd2(GetDefaultWd2())
126 {
127  for(unsigned char st = 0; st < splice_type_count_32; ++st) {
128  m_Wi[st] = GetDefaultWi(st);
129  }
130 }
131 
132 
133 CSplicedAligner32::CSplicedAligner32(const string& seq1, const string& seq2)
134  : CSplicedAligner(seq1, seq2),
135  m_Wd1(GetDefaultWd1()),
136  m_Wd2(GetDefaultWd2())
137 {
138  for(unsigned char st = 0; st < splice_type_count_32; ++st) {
139  m_Wi[st] = GetDefaultWi(st);
140  }
141 }
142 
143 
145 {
146  switch(splice_type) {
147  case 0: return -15; // GT/AG
148  case 1: return -18; // GC/AG
149  case 2: return -21; // AT/AC
150  default: {
152  eInvalidSpliceTypeIndex,
154  }
155  }
156 }
157 
158 
159 // Evaluate dynamic programming matrix. Create transcript.
161 {
162  // use the banded version if there is no space for introns
163  const Int8 len_dif (data->m_len2 - data->m_len1);
164  if(len_dif < 2 * int (m_IntronMinSize) / 3) {
165  const Uint1 where (len_dif < 0? 0: 1);
166  const size_t shift (abs(len_dif) / 2);
167  const size_t band (abs(len_dif) + 2*(max(data->m_len1,data->m_len2)/20 + 1));
168  SetShift(where, shift);
169  SetBand(band);
170  return CBandAligner::x_Align(data);
171  }
172 
173  // redefine TScore as a floating-point type for this procedure only
174  typedef double TScore;
175  const TScore cds_penalty_extra = -2e-6;
176 
177  const size_t N1 = data->m_len1 + 1;
178  const size_t N2 = data->m_len2 + 1;
179 
180  vector<TScore> stl_rowV (N2), stl_rowF (N2);
181  TScore* rowV = &stl_rowV[0];
182  TScore* rowF = &stl_rowF[0];
183 
184  // index calculation: [i,j] = i*n2 + j
185  SAllocator<Uint4> alloc_bm (N1*N2);
186  Uint4* backtrace_matrix (alloc_bm.GetPointer());
187 
188  TScore* pV = rowV - 1;
189 
190  const char* seq1 = m_Seq1 + data->m_offset1 - 1;
191  const char* seq2 = m_Seq2 + data->m_offset2 - 1;
192 
193  const TNCBIScore (*sm) [NCBI_FSM_DIM] = m_ScoreMatrix.s;
194 
195  bool bFreeGapLeft1 = data->m_esf_L1 && data->m_offset1 == 0;
196  bool bFreeGapRight1 = data->m_esf_R1 &&
197  m_SeqLen1 == data->m_offset1 + data->m_len1;
198 
199  bool bFreeGapLeft2 = data->m_esf_L2 && data->m_offset1 == 0;
200  bool bFreeGapRight2 = data->m_esf_R2 &&
201  m_SeqLen2 == data->m_offset2 + data->m_len2;
202 
203  TScore wgleft1 = bFreeGapLeft1? 0: m_Wg;
204  TScore wsleft1 = bFreeGapLeft1? 0: m_Ws;
205  TScore wg1 = wgleft1, ws1 = wsleft1;
206 
207  // recurrences
208  TScore wgleft2 = bFreeGapLeft2? 0: m_Wg;
209  TScore wsleft2 = bFreeGapLeft2? 0: m_Ws;
210  TScore V = 0;
211  TScore V0 = 0;
212  TScore E, G, n0;
213  Uint8 type;
214 
215  // store candidate donors
216  size_t* jAllDonors [splice_type_count_32];
217  TScore* vAllDonors [splice_type_count_32];
218  vector<size_t> stl_jAllDonors (splice_type_count_32 * N2);
219  vector<TScore> stl_vAllDonors (splice_type_count_32 * N2);
220  for(unsigned char st = 0; st < splice_type_count_32; ++st) {
221  jAllDonors[st] = &stl_jAllDonors[st*N2];
222  vAllDonors[st] = &stl_vAllDonors[st*N2];
223  }
224  size_t jTail[splice_type_count_32], jHead[splice_type_count_32];
225  TScore vBestDonor [splice_type_count_32];
226  size_t jBestDonor [splice_type_count_32] = {0};
227 
228  // place to store gap opening starts
229  size_t ins_start;
230  vector<size_t> stl_del_start(N2);
231  size_t* del_start = &stl_del_start[0];
232 
233  // donor/acceptor matrix
234  const Uint1 * dnr_acc_matrix = g_dnr_acc_matrix.GetMatrix();
235 
236  // fake row (above lambda)
237  rowV[0] = kInfMinus;
238  size_t k;
239  for (k = 0; k < N2; k++) {
240  rowV[k] = rowF[k] = kInfMinus;
241  del_start[k] = k;
242  }
243  k = 0;
244 
245  size_t cds_start = m_cds_start, cds_stop = m_cds_stop;
246  if(cds_start < cds_stop) {
247  cds_start -= data->m_offset1;
248  cds_stop -= data->m_offset1;
249  }
250 
251  size_t i, j = 0, k0;
252  unsigned char ci;
253  for(i = 0; i < N1; ++i, j = 0) {
254 
255  V = i > 0? (V0 += wsleft2) : 0;
256  E = kInfMinus;
257  ins_start = k0 = k;
258  backtrace_matrix[k++] = kTypeGap; // | del_start[0]
259  ci = i > 0? seq1[i]: 'N';
260 
261  for(unsigned char st = 0; st < splice_type_count_32; ++st) {
262  jTail[st] = jHead[st] = 0;
263  vBestDonor[st] = kInfMinus;
264  }
265 
266  if(i == N1 - 1 && bFreeGapRight1) {
267  wg1 = ws1 = 0;
268  }
269 
270  TScore wg2 = m_Wg, ws2 = m_Ws;
271 
272  // detect donor candidate
273  if(N2 > 2) {
274  unsigned char d1 = seq2[1], d2 = seq2[2];
275  Uint1 dnr_type = 0xF0 & dnr_acc_matrix[(size_t(d1)<<8)|d2];
276 
277  for(Uint1 st = 0; st < splice_type_count_32; ++st ) {
278  jAllDonors[st][jTail[st]] = j;
279  if(dnr_type & (0x10 << st)) {
280  vAllDonors[st][jTail[st]] =
281  ( d1 == g_nwspl32_donor[st][0] &&
282  d2 == g_nwspl32_donor[st][1] ) ? V: (V + m_Wd1);
283  }
284  else { // both chars distorted
285  vAllDonors[st][jTail[st]] = V + m_Wd2;
286  }
287  ++(jTail[st]);
288  }
289  }
290 
291  if(cds_start <= i && i < cds_stop) {
292 
293  if(i != 0 || ! bFreeGapLeft1) {
294  ws1 += cds_penalty_extra;
295  }
296  if(j != 0 || ! bFreeGapLeft2) {
297  ws2 += cds_penalty_extra;
298  }
299  }
300 
301  for (j = 1; j < N2; ++j, ++k) {
302 
303  G = pV[j] + sm[ci][(unsigned char)seq2[j]];
304  pV[j] = V;
305 
306  n0 = V + wg1;
307  if(E >= n0) {
308  E += ws1; // continue the gap
309  }
310  else {
311  E = n0 + ws1; // open a new gap
312  ins_start = k-1;
313  }
314 
315  if(j == N2 - 1 && bFreeGapRight2) {
316  wg2 = ws2 = 0;
317  }
318  n0 = rowV[j] + wg2;
319  if(rowF[j] >= n0) {
320  rowF[j] += ws2;
321  }
322  else {
323  rowF[j] = n0 + ws2;
324  del_start[j] = k-N2;
325  }
326 
327  // evaluate the score (V)
328  if (E >= rowF[j]) {
329  if(E >= G) {
330  V = E;
331  type = kTypeGap | ins_start;
332  }
333  else {
334  V = G;
335  type = kTypeDiag;
336  }
337  } else {
338  if(rowF[j] >= G) {
339  V = rowF[j];
340  type = kTypeGap | del_start[j];
341  }
342  else {
343  V = G;
344  type = kTypeDiag;
345  }
346  }
347 
348  // find out if there are new donors
349  for(unsigned char st = 0; st < splice_type_count_32; ++st) {
350 
351  if(jTail[st] > jHead[st]) {
352  if(j - jAllDonors[st][jHead[st]] >= m_IntronMinSize) {
353  if(vAllDonors[st][jHead[st]] > vBestDonor[st]) {
354  vBestDonor[st] = vAllDonors[st][jHead[st]];
355  jBestDonor[st] = jAllDonors[st][jHead[st]];
356  }
357  ++(jHead[st]);
358  }
359  }
360  }
361 
362  // check splice signal
363  Uint8 dnr_pos = kMax_UI4;
364  unsigned char c1 = seq2[j-1], c2 = seq2[j];
365  Uint1 acc_mask = 0x0F & dnr_acc_matrix[(size_t(c1)<<8)|c2];
366  for(Uint1 st = 0; st < splice_type_count_32; ++st ) {
367  if(acc_mask & (0x01 << st)) {
368  TScore vAcc = vBestDonor[st] + m_Wi[st];
369  if( c1 != g_nwspl32_acceptor[st][0] ||
370  c2 != g_nwspl32_acceptor[st][1] ) {
371 
372  vAcc += m_Wd1;
373  }
374  if(vAcc > V) {
375  V = vAcc;
376  dnr_pos = k0 + jBestDonor[st];
377  }
378  }
379  else { // try arbitrary splice
380  TScore vAcc = vBestDonor[st] + m_Wi[st] + m_Wd2;
381  if(vAcc > V) {
382  V = vAcc;
383  dnr_pos = k0 + jBestDonor[st];
384  }
385  }
386  }
387 
388  if(dnr_pos != kMax_UI4) {
389  type = kTypeIntron | dnr_pos;
390  }
391 
392  backtrace_matrix[k] = type;
393 
394  // detect donor candidates
395  if(j < N2 - 2) {
396  unsigned char d1 = seq2[j+1], d2 = seq2[j+2];
397  Uint1 dnr_mask = 0xF0 & dnr_acc_matrix[(size_t(d1)<<8)|d2];
398  for(Uint1 st = 0; st < splice_type_count_32; ++st ) {
399  if( dnr_mask & (0x10 << st) ) {
400  if( d1 == g_nwspl32_donor[st][0] &&
401  d2 == g_nwspl32_donor[st][1] ) {
402 
403  if(V > vBestDonor[st]) {
404  jAllDonors[st][jTail[st]] = j;
405  vAllDonors[st][jTail[st]] = V;
406  ++(jTail[st]);
407  }
408  } else {
409  TScore v = V + m_Wd1;
410  if(v > vBestDonor[st]) {
411  jAllDonors[st][jTail[st]] = j;
412  vAllDonors[st][jTail[st]] = v;
413  ++(jTail[st]);
414  }
415  }
416  }
417  else { // both chars distorted
418  TScore v = V + m_Wd2;
419  if(v > vBestDonor[st]) {
420  jAllDonors[st][jTail[st]] = j;
421  vAllDonors[st][jTail[st]] = v;
422  ++(jTail[st]);
423  }
424  }
425  }
426  }
427  }
428 
429  pV[j] = V;
430 
431  if(i == 0) {
432  V0 = wgleft2;
433  wg1 = m_Wg;
434  ws1 = m_Ws;
435  }
436 
437  }
438 
439  try {
440  x_DoBackTrace(backtrace_matrix, data);
441  }
442  catch(exception&) { // GCC hack
443  throw;
444  }
445 
446  return CNWAligner::TScore(V);
447 }
448 
449 
450 
451 // perform backtrace step;
452 void CSplicedAligner32::x_DoBackTrace (const Uint4* backtrace_matrix,
454 {
455  const size_t N1 = data->m_len1 + 1;
456  const size_t N2 = data->m_len2 + 1;
457 
458  data->m_transcript.clear();
459  data->m_transcript.reserve(N1 + N2);
460 
461  size_t k = N1*N2 - 1;
462  size_t i1 = data->m_offset1 + data->m_len1 - 1;
463  size_t i2 = data->m_offset2 + data->m_len2 - 1;
464 
465  const Uint4 mask_jump = 0x3FFFFFFF;
466  const Uint4 mask_type = ~mask_jump;
467 
468  while (k != 0) {
469 
470  Uint4 Key = backtrace_matrix[k];
471  Uint4 type = Key & mask_type;
472 
473  if(type == kTypeDiag) {
474  data->m_transcript.push_back(x_GetDiagTS(i1--, i2--));
475  k -= N2 + 1;
476  }
477  else {
478 
479  Uint4 k2 = (Key & mask_jump);
480  if(k2 >= k) {
481  NCBI_THROW(CAlgoAlignException, eInternal,
483  }
484 
486  Uint8 decr;
487  if(type == kTypeIntron) {
488  ts = eTS_Intron;
489  decr = 1;
490  }
491  else {
492  Uint8 kdel = k / N2, k2del = k2 / N2;
493  Uint8 kmod = k % N2, k2mod = k2 % N2;
494  if(kdel == k2del) {
495  ts = eTS_Insert;
496  decr = 1;
497  }
498  else if(kmod == k2mod) {
499  ts = eTS_Delete;
500  decr = N2;
501  }
502  else {
503  // ts = eTS_DiagSpace (not yet supported)
504  NCBI_THROW(CAlgoAlignException, eInternal,
506  }
507  }
508 
509  for(; k > k2; k -= decr) {
510  data->m_transcript.push_back(ts);
511  if(decr == 1) {
512  --i2;
513  }
514  else {
515  --i1;
516  }
517  }
518  if(k != k2) {
519  NCBI_THROW(CAlgoAlignException, eInternal,
521  }
522  }
523  }
524 }
525 
526 
527 
529  const TTranscript& transcript,
530  size_t start1, size_t start2) const
531 {
532  bool nucl_mode;
533  if(start1 == kMax_UInt && start2 == kMax_UInt) {
534  nucl_mode = true;
535  }
536  else if(start1 != kMax_UInt && start2 != kMax_UInt) {
537  nucl_mode = false;
538  }
539  else {
540  NCBI_THROW(CAlgoAlignException, eInternal,
542  }
543 
544  const size_t dim = transcript.size();
545 
546  TScore score = 0;
547 
548  const char* p1 = m_Seq1 + start1;
549  const char* p2 = m_Seq2 + start2;
550 
551  const TNCBIScore (*sm) [NCBI_FSM_DIM] = m_ScoreMatrix.s;
552 
553  char state1; // 0 = normal, 1 = gap, 2 = intron
554  char state2; // 0 = normal, 1 = gap
555 
556  switch( transcript[0] ) {
557 
558  case eTS_Match:
559  case eTS_Replace:
560  state1 = state2 = 0;
561  break;
562 
563  case eTS_Insert:
564  state1 = 1; state2 = 0; score += m_Wg;
565  break;
566 
567  case eTS_Intron:
568  state1 = 0; state2 = 0;
569  break; // intron flag set later
570 
571  case eTS_Delete:
572  state1 = 0; state2 = 1; score += m_Wg;
573  break;
574 
575  default: {
576  NCBI_THROW(CAlgoAlignException, eInternal,
578  }
579  }
580 
581  for(size_t i = 0; i < dim; ++i) {
582 
583  ETranscriptSymbol ts = transcript[i];
584  switch(ts) {
585 
586  case eTS_Replace:
587  case eTS_Match: {
588  if(nucl_mode) {
589  score += (ts == eTS_Match)? m_Wm: m_Wms;
590  }
591  else {
592  unsigned char c1 = *p1;
593  unsigned char c2 = *p2;
594  score += sm[c1][c2];
595  ++p1; ++p2;
596  }
597  state1 = state2 = 0;
598  }
599  break;
600 
601  case eTS_Insert: {
602  if(state1 != 1) score += m_Wg;
603  state1 = 1; state2 = 0;
604  score += m_Ws;
605  ++p2;
606  }
607  break;
608 
609  case eTS_Delete: {
610  if(state2 != 1) score += m_Wg;
611  state1 = 0; state2 = 1;
612  score += m_Ws;
613  ++p1;
614  }
615  break;
616 
617  case eTS_Intron: {
618 
619  if(state1 != 2) {
620  if(nucl_mode) {
621  score += m_Wi[0];
622  }
623  else {
624  for(unsigned char k = 0; k < splice_type_count_32; ++k) {
625  if(*p2 == g_nwspl32_donor[k][0] &&
626  *(p2 + 1) == g_nwspl32_donor[k][1]) {
627 
628  score += m_Wi[k];
629  break;
630  }
631  }
632  }
633  }
634  state1 = 2; state2 = 0;
635  ++p2;
636  }
637  break;
638 
639  default: {
640  NCBI_THROW(CAlgoAlignException, eInternal,
642  }
643  }
644  }
645 
646  if(m_esf_R1) {
647  size_t g = 0;
648  for(Int8 i = dim - 1; i >= 0; --i) {
649  if(transcript[i] == eTS_Insert) ++g; else break;
650  }
651  if(g > 0) {
652  score -= (m_Wg + g*m_Ws);
653  }
654  }
655 
656  if(m_esf_R2) {
657  size_t g = 0;
658  for(Int8 i = dim - 1; i >= 0; --i) {
659  if(transcript[i] == eTS_Delete) ++g; else break;
660  }
661  if(g > 0) {
662  score -= (m_Wg + g*m_Ws);
663  }
664  }
665 
666  if(m_esf_L1) {
667  size_t g = 0;
668  for(size_t i = 0; i < dim; ++i) {
669  if(transcript[i] == eTS_Insert) ++g; else break;
670  }
671  if(g > 0) {
672  score -= (m_Wg + g*m_Ws);
673  }
674  }
675 
676  if(m_esf_L2) {
677  size_t g = 0;
678  for(size_t i = 0; i < dim; ++i) {
679  if(transcript[i] == eTS_Delete) ++g; else break;
680  }
681  if(g > 0) {
682  score -= (m_Wg + g*m_Ws);
683  }
684  }
685 
686  return score;
687 }
688 
689 
const Uint1 * GetMatrix() const
void x_Set(char c1, char c2, Uint1 val)
#define G(x, y, z)
Definition: md4.c:179
static int type
Definition: getdata.c:31
void SetBand(size_t band)
virtual ETranscriptSymbol x_GetDiagTS(size_t i1, size_t i2) const
Definition: nw_aligner.cpp:707
const char * m_Seq1
Definition: nw_aligner.hpp:295
TScore m_Ws
Definition: nw_aligner.hpp:271
SNCBIFullScoreMatrix m_ScoreMatrix
Definition: nw_aligner.hpp:281
void SetShift(Uint1 where, size_t offset)
TScore m_Wg
Definition: nw_aligner.hpp:270
virtual TScore x_Align(CNWAligner::SAlignInOut *data)
size_t m_SeqLen1
Definition: nw_aligner.hpp:296
const char * m_Seq2
Definition: nw_aligner.hpp:298
vector< ETranscriptSymbol > TTranscript
Definition: nw_aligner.hpp:199
TScore m_Wms
Definition: nw_aligner.hpp:269
TScore m_Wm
Definition: nw_aligner.hpp:268
size_t m_SeqLen2
Definition: nw_aligner.hpp:299
virtual TScore x_Align(CNWAligner::SAlignInOut *data)
TScore m_Wi[splice_type_count_32]
void x_DoBackTrace(const Uint4 *backtrace_matrix, CNWAligner::SAlignInOut *data)
virtual TScore ScoreFromTranscript(const TTranscript &transcript, size_t start1=kMax_UInt, size_t start2=kMax_UInt) const
const size_t splice_type_count_32
static TScore GetDefaultWi(unsigned char splice_type)
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
Definition: ncbiexpt.hpp:704
uint8_t Uint1
1-byte (8-bit) unsigned integer
Definition: ncbitype.h:99
uint32_t Uint4
4-byte (32-bit) unsigned integer
Definition: ncbitype.h:103
int64_t Int8
8-byte (64-bit) signed integer
Definition: ncbitype.h:104
uint64_t Uint8
8-byte (64-bit) unsigned integer
Definition: ncbitype.h:105
#define kMax_UInt
Definition: ncbi_limits.h:185
#define kMax_UI4
Definition: ncbi_limits.h:219
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
int i
#define abs(a)
Definition: ncbi_heapmgr.c:130
const double E
T max(T x_, T y_)
const Uint4 kTypeGap
const Uint4 kTypeIntron
const Uint4 kTypeDiag
const unsigned char g_nwspl32_acceptor[splice_type_count_32][2]
const unsigned char g_nwspl32_donor[splice_type_count_32][2]
#define NCBI_FSM_DIM
Recommended approach: unpack and index directly.
Definition: raw_scoremat.h:85
int TNCBIScore
data types
Definition: raw_scoremat.h:45
const char g_msg_InconsistentArguments[]
Definition: messages.hpp:27
const char g_msg_InvalidTranscriptSymbol[]
Definition: messages.hpp:10
const char g_msg_InvalidSpliceTypeIndex[]
Definition: messages.hpp:21
const char g_msg_InvalidBacktraceData[]
Definition: messages.hpp:12
TNCBIScore s[128][128]
Definition: raw_scoremat.h:87
Definition: type.c:6
int g(Seg_Gsm *spe, Seq_Mtf *psm, Thd_Gsm *tdg)
Definition: thrddgri.c:44
Modified on Wed Feb 28 07:13:35 2024 by modify_doxy.py rev. 669887