NCBI C++ ToolKit
Functions
lookup_wrap.c File Reference

Wrapper for different flavors of lookup tables allowing a uniform interface in the code. More...

#include <algo/blast/core/lookup_wrap.h>
#include <algo/blast/core/blast_aalookup.h>
#include <algo/blast/core/blast_nalookup.h>
#include <algo/blast/core/phi_lookup.h>
#include <algo/blast/core/blast_filter.h>
#include <algo/blast/core/lookup_util.h>
#include <algo/blast/core/blast_rps.h>
#include <algo/blast/core/blast_encoding.h>
+ Include dependency graph for lookup_wrap.c:

Go to the source code of this file.

Go to the SVN repository for this file.

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 different flavors of lookup tables allowing a uniform interface in the code.

The wrapper (LookupTableWrap) contains an unsigned byte specifying the type of lookup table as well as a void pointer pointing to the actual lookup table. Examples of different types of lookup tables are those for protein queries, the "standard" nucleotide one, the megablast lookup table, etc.

Definition in file lookup_wrap.c.

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 Tue Apr 23 07:40:15 2024 by modify_doxy.py rev. 669887