NCBI C++ ToolKit
Functions
blast_aascan.c File Reference

Functions for accessing hits in the protein BLAST lookup table. More...

#include <algo/blast/core/blast_aascan.h>
#include <algo/blast/core/blast_aalookup.h>
#include "masksubj.inl"
+ Include dependency graph for blast_aascan.c:

Go to the source code of this file.

Go to the SVN repository for this file.

Functions

static Int4 s_BlastAaScanSubject (const LookupTableWrap *lookup_wrap, const BLAST_SequenceBlk *subject, BlastOffsetPair *offset_pairs, Int4 array_size, Int4 *s_range)
 Scans the subject sequence from "offset" to the end of the sequence. More...
 
static Int4 s_BlastSmallAaScanSubject (const LookupTableWrap *lookup_wrap, const BLAST_SequenceBlk *subject, BlastOffsetPair *offset_pairs, Int4 array_size, Int4 *s_range)
 same function for small lookup table More...
 
static Int4 s_BlastCompressedAaScanSubject (const LookupTableWrap *lookup_wrap, const BLAST_SequenceBlk *subject, BlastOffsetPair *offset_pairs, Int4 array_size, Int4 *s_range)
 Scans the subject sequence from "offset" to the end of the sequence, assuming a compressed protein alphabet Copies at most array_size hits. More...
 
static void s_AddToRPSBucket (RPSBucket *b, Uint4 q_off, Uint4 s_off)
 Add one query-subject pair to the list of such pairs retrieved from the RPS blast lookup table. More...
 
Int4 BlastRPSScanSubject (const LookupTableWrap *lookup_wrap, const BLAST_SequenceBlk *sequence, Int4 *offset)
 Scans the RPS query sequence from "offset" to the end of the sequence. More...
 
void BlastChooseProteinScanSubject (LookupTableWrap *lookup_wrap)
 Choose the most appropriate function to scan through protein subject sequences. More...
 

Detailed Description

Functions for accessing hits in the protein BLAST lookup table.

Definition in file blast_aascan.c.

Function Documentation

◆ BlastChooseProteinScanSubject()

void BlastChooseProteinScanSubject ( LookupTableWrap lookup_wrap)

◆ BlastRPSScanSubject()

Int4 BlastRPSScanSubject ( const LookupTableWrap lookup_wrap,
const BLAST_SequenceBlk sequence,
Int4 offset 
)

Scans the RPS query sequence from "offset" to the end of the sequence.

Copies at most array_size hits. Returns the number of hits found. If there isn't enough room to copy all the hits, return early, and update "offset".

Parameters
lookup_wrapthe lookup table [in]
sequencethe subject sequence [in]
offsetthe offset in the subject at which to begin scanning [in/out]
Returns
The number of hits found.

Definition at line 450 of file blast_aascan.c.

References ASSERT, ComputeTableIndex(), ComputeTableIndexIncremental(), RPSBackboneCell::entries, eRPSLookupTable, for(), i, BLAST_SequenceBlk::length, lookup(), LookupTableWrap::lut, LookupTableWrap::lut_type, NULL, RPSBackboneCell::num_used, offset, PV_ARRAY_BTS, PV_ARRAY_TYPE, PV_TEST, RPS_BUCKET_SIZE, RPS_HITS_PER_CELL, s_AddToRPSBucket(), and BLAST_SequenceBlk::sequence.

Referenced by s_BlastRPSWordFinder_OneHit(), and s_BlastRPSWordFinder_TwoHit().

◆ s_AddToRPSBucket()

static void s_AddToRPSBucket ( RPSBucket b,
Uint4  q_off,
Uint4  s_off 
)
static

Add one query-subject pair to the list of such pairs retrieved from the RPS blast lookup table.

Parameters
bthe List in which the current pair will be placed [in/out]
q_offquery offset [in]
s_offsubject offset [in]

Definition at line 422 of file blast_aascan.c.

References b, i, BlastOffsetPair::q_off, BlastOffsetPair::qs_offsets, and BlastOffsetPair::s_off.

Referenced by BlastRPSScanSubject().

◆ s_BlastAaScanSubject()

static Int4 s_BlastAaScanSubject ( const LookupTableWrap lookup_wrap,
const BLAST_SequenceBlk subject,
BlastOffsetPair offset_pairs,
Int4  array_size,
Int4 s_range 
)
static

Scans the subject sequence from "offset" to the end of the sequence.

Copies at most array_size hits. Returns the number of hits found. If there isn't enough room to copy all the hits, return early, and update "offset".

Parameters
lookup_wrapthe lookup table [in]
subjectthe subject sequence [in]
offset_pairsArray to which hits will be copied [out]
array_sizelength of the offset arrays [in]
Returns
The number of hits found.

Definition at line 48 of file blast_aascan.c.

References AA_HITS_PER_CELL, ASSERT, ComputeTableIndex(), ComputeTableIndexIncremental(), eAaLookupTable, eBackbone, AaLookupBackboneCell::entries, i, lookup(), LookupTableWrap::lut, LookupTableWrap::lut_type, NULL, AaLookupBackboneCell::num_used, AaLookupBackboneCell::overflow_cursor, AaLookupBackboneCell::payload, PV_ARRAY_BTS, PV_ARRAY_TYPE, PV_TEST, s_DetermineScanningOffsets(), and subject.

Referenced by BlastChooseProteinScanSubject().

◆ s_BlastCompressedAaScanSubject()

static Int4 s_BlastCompressedAaScanSubject ( const LookupTableWrap lookup_wrap,
const BLAST_SequenceBlk subject,
BlastOffsetPair offset_pairs,
Int4  array_size,
Int4 s_range 
)
static

Scans the subject sequence from "offset" to the end of the sequence, assuming a compressed protein alphabet Copies at most array_size hits.

Returns the number of hits found. If there isn't enough room to copy all the hits, return early, and update "offset".

Parameters
lookup_wrapthe lookup table [in]
subjectthe subject sequence [in]
offsetthe offset in the subject at which to begin scanning [in/out]
offset_pairsArray to which hits will be copied [out]
array_sizelength of the offset arrays [in]
Returns
The number of hits found.

Definition at line 234 of file blast_aascan.c.

References ASSERT, COMPRESSED_HITS_CELL_MASK, COMPRESSED_HITS_PER_BACKBONE_CELL, COMPRESSED_HITS_PER_OVERFLOW_CELL, eCompressedAaLookupTable, CompressedMixedOffsets::head, i, lookup(), LookupTableWrap::lut, LookupTableWrap::lut_type, CompressedOverflowCell::next, NULL, CompressedLookupBackboneCell::num_used, CompressedLookupBackboneCell::overflow_list, CompressedLookupBackboneCell::payload, PV_ARRAY_TYPE, PV_TEST, BlastOffsetPair::q_off, BlastOffsetPair::qs_offsets, CompressedLookupBackboneCell::query_offset, CompressedMixedOffsets::query_offsets, CompressedOverflowCell::query_offsets, CompressedLookupBackboneCell::query_offsets, s_ComputeCompressedIndex(), s_DetermineScanningOffsets(), BlastOffsetPair::s_off, subject, and while().

Referenced by BlastChooseProteinScanSubject().

◆ s_BlastSmallAaScanSubject()

static Int4 s_BlastSmallAaScanSubject ( const LookupTableWrap lookup_wrap,
const BLAST_SequenceBlk subject,
BlastOffsetPair offset_pairs,
Int4  array_size,
Int4 s_range 
)
static
Modified on Fri Sep 20 14:57:28 2024 by modify_doxy.py rev. 669887