NCBI C++ ToolKit
Classes | Macros | Typedefs | Functions
lookup_wrap.h File Reference

Wrapper for all lookup tables used in BLAST. More...

#include <algo/blast/core/ncbi_std.h>
#include <algo/blast/core/blast_def.h>
#include <algo/blast/core/blast_options.h>
#include <algo/blast/core/blast_rps.h>
#include <algo/blast/core/blast_stat.h>
#include <algo/blast/core/blast_seqsrc.h>
+ Include dependency graph for lookup_wrap.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Go to the SVN repository for this file.

Classes

struct  LookupTableWrap
 Wrapper structure for different types of BLAST lookup tables. More...
 

Macros

#define OFFSET_ARRAY_SIZE   4096
 Default size of offset arrays filled in a single ScanSubject call. More...
 

Typedefs

typedef struct LookupTableWrap LookupTableWrap
 Wrapper structure for different types of BLAST lookup tables. More...
 
typedef Boolean(* T_Lookup_Callback) (const LookupTableWrap *, Int4, Int4)
 Function pointer type to check the presence of index->q_off pair. More...
 

Functions

Int2 LookupTableWrapInit (BLAST_SequenceBlk *query, const LookupTableOptions *lookup_options, const QuerySetUpOptions *query_options, BlastSeqLoc *lookup_segments, BlastScoreBlk *sbp, LookupTableWrap **lookup_wrap_ptr, const BlastRPSInfo *rps_info, Blast_Message **error_msg, BlastSeqSrc *seqsrc)
 Create the lookup table for all query words. More...
 
Int2 LookupTableWrapInit_MT (BLAST_SequenceBlk *query, const LookupTableOptions *lookup_options, const QuerySetUpOptions *query_options, BlastSeqLoc *lookup_segments, BlastScoreBlk *sbp, LookupTableWrap **lookup_wrap_ptr, const BlastRPSInfo *rps_info, Blast_Message **error_msg, BlastSeqSrc *seqsrc, Uint4 num_threads)
 Create the lookup table for all query words (possibly multithreaded, depends on implementation). More...
 
LookupTableWrapLookupTableWrapFree (LookupTableWrap *lookup)
 Deallocate memory for the lookup table. More...
 
Int4 GetOffsetArraySize (LookupTableWrap *lookup)
 Determine the size of the offsets arrays to be filled by the ScanSubject function. More...
 

Detailed Description

Wrapper for all lookup tables used in BLAST.

Definition in file lookup_wrap.h.

Macro Definition Documentation

◆ OFFSET_ARRAY_SIZE

#define OFFSET_ARRAY_SIZE   4096

Default size of offset arrays filled in a single ScanSubject call.

Definition at line 119 of file lookup_wrap.h.

Typedef Documentation

◆ LookupTableWrap

Wrapper structure for different types of BLAST lookup tables.

◆ T_Lookup_Callback

typedef Boolean(* T_Lookup_Callback) (const LookupTableWrap *, Int4, Int4)

Function pointer type to check the presence of index->q_off pair.

Definition at line 66 of file lookup_wrap.h.

Function Documentation

◆ GetOffsetArraySize()

Int4 GetOffsetArraySize ( LookupTableWrap lookup)

◆ LookupTableWrapFree()

LookupTableWrap* LookupTableWrapFree ( LookupTableWrap lookup)

◆ LookupTableWrapInit()

Int2 LookupTableWrapInit ( BLAST_SequenceBlk query,
const LookupTableOptions lookup_options,
const QuerySetUpOptions query_options,
BlastSeqLoc lookup_segments,
BlastScoreBlk sbp,
LookupTableWrap **  lookup_wrap_ptr,
const BlastRPSInfo rps_info,
Blast_Message **  error_msg,
BlastSeqSrc seqsrc 
)

Create the lookup table for all query words.

Parameters
queryThe query sequence [in]
lookup_optionsWhat kind of lookup table to build? [in]
query_optionsoptions for query setup [in]
lookup_segmentsLocations on query to be used for lookup table construction [in]
sbpScoring block containing matrix [in]
lookup_wrap_ptrThe initialized lookup table [out]
rps_infoStructure containing RPS blast setup information [in]
error_msgmessage with warning or errors [in|out]
seqsrcDatabase sequences [in]

Definition at line 47 of file lookup_wrap.c.

References LookupTableWrapInit_MT(), and query.

Referenced by AascanTestFixture::AascanTestFixture(), BOOST_AUTO_TEST_CASE(), CompressedAascanTestFixture::CompressedAascanTestFixture(), CompressedAalookupTestFixture::FillLookupTable(), AalookupTestFixture::FillLookupTable(), s_GetInitialWordParameters(), LinkHspTestFixture::setupCutoffScores(), TestFixture::SetUpLookupTable(), CPhiblastTestFixture::setUpLookupTable(), and CSeedTop::x_MakeLookupTable().

◆ LookupTableWrapInit_MT()

Int2 LookupTableWrapInit_MT ( BLAST_SequenceBlk query,
const LookupTableOptions lookup_options,
const QuerySetUpOptions query_options,
BlastSeqLoc lookup_segments,
BlastScoreBlk sbp,
LookupTableWrap **  lookup_wrap_ptr,
const BlastRPSInfo rps_info,
Blast_Message **  error_msg,
BlastSeqSrc seqsrc,
Uint4  num_threads 
)

Create the lookup table for all query words (possibly multithreaded, depends on implementation).

Parameters
queryThe query sequence [in]
lookup_optionsWhat kind of lookup table to build? [in]
query_optionsoptions for query setup [in]
lookup_segmentsLocations on query to be used for lookup table construction [in]
sbpScoring block containing matrix [in]
lookup_wrap_ptrThe initialized lookup table [out]
rps_infoStructure containing RPS blast setup information [in]
error_msgmessage with warning or errors [in|out]
seqsrcDatabase sequences [in]
num_threadsNumber of threads to use [in]

Definition at line 61 of file lookup_wrap.c.

References ASSERT, Blast_MaskUnsupportedAA(), BLASTAA_SIZE, BlastAaLookupFinalize(), BlastAaLookupIndexQuery(), BlastAaLookupTableNew(), BlastChooseNaLookupTable(), BlastCompressedAaLookupTableNew(), BlastMBLookupTableNew(), BlastNaHashLookupTableNew(), BlastNaLookupTableNew(), BlastSmallNaLookupTableNew(), calloc(), SBlastScoreMatrix::data, eAaLookupTable, eBackbone, eCompressedAaLookupTable, eIndexedMBLookupTable, eMBLookupTable, eMixedMBLookupTable, eNaHashLookupTable, eNaLookupTable, ePhiLookupTable, ePhiNaLookupTable, eRPSLookupTable, eSmallbone, eSmallNaLookupTable, EstimateNumTableEntries(), FALSE, INT2_MAX, lookup(), LookupTableWrap::lut, LookupTableOptions::lut_type, LookupTableWrap::lut_type, BlastScoreBlk::matrix, NULL, LookupTableOptions::phi_pattern, BlastScoreBlk::psi_matrix, SPsiBlastScoreMatrix::pssm, query, RPSLookupTableNew(), SPHIPatternSearchBlkNew(), and TRUE.

Referenced by CSetupFactory::CreateLookupTable(), and LookupTableWrapInit().

Modified on Fri Feb 23 11:48:48 2024 by modify_doxy.py rev. 669887