IntaRNA 3.4.1
RNA-RNA interaction prediction | C++ API
Loading...
Searching...
No Matches
Classes | Public Member Functions | Protected Member Functions | List of all members
IntaRNA::PredictorSeedExtensionKinetic Class Reference

#include <PredictorSeedExtensionKinetic.h>

Inheritance diagram for IntaRNA::PredictorSeedExtensionKinetic:
Inheritance graph
[legend]
Collaboration diagram for IntaRNA::PredictorSeedExtensionKinetic:
Collaboration graph
[legend]

Public Member Functions

 PredictorSeedExtensionKinetic (const InteractionEnergy &energy, OutputHandler &output, PredictionTracker *predTracker, SeedHandler *seedHandler, const char score='A')
 
virtual ~PredictorSeedExtensionKinetic ()
 
void predict (const IndexRange &r1=IndexRange(0, RnaSequence::lastPos), const IndexRange &r2=IndexRange(0, RnaSequence::lastPos)) override
 
- Public Member Functions inherited from IntaRNA::PredictorMfe
 PredictorMfe (const InteractionEnergy &energy, OutputHandler &output, PredictionTracker *predTracker)
 
virtual ~PredictorMfe ()
 
- Public Member Functions inherited from IntaRNA::Predictor
 Predictor (const InteractionEnergy &energy, OutputHandler &output, PredictionTracker *predTracker)
 
virtual ~Predictor ()
 
Z_type getZall () const
 

Protected Member Functions

void traceBack (Interaction &interaction) override
 
void getNextBest (Interaction &interaction) override
 
- Protected Member Functions inherited from IntaRNA::PredictorMfe
virtual void initOptima ()
 
bool isValidOutputSite (const size_t i1, const size_t j1, const size_t i2, const size_t j2) const
 
virtual void updateOptima (const size_t i1, const size_t j1, const size_t i2, const size_t j2, const E_type energy, const bool isHybridE, const bool incrementZall)
 
virtual void updateMfe4leftEnd (const size_t i1, const size_t j1, const size_t i2, const size_t j2, const Interaction &curInteraction)
 
virtual void reportOptima ()
 
- Protected Member Functions inherited from IntaRNA::Predictor
virtual void updateZall (const size_t i1, const size_t j1, const size_t i2, const size_t j2, const E_type energy, const bool isHybridE)
 
void incrementZall (const Z_type partZ)
 

Additional Inherited Members

- Static Public Member Functions inherited from IntaRNA::Predictor
static size_t getMaxInteractionWidth (const size_t w, const size_t maxLoopSize)
 
- Protected Types inherited from IntaRNA::PredictorMfe
typedef BestInteraction< E_type > BestInteractionE
 BestInteraction that stores an energy value.
 
typedef BestInteraction< Z_type > BestInteractionZ
 BestInteraction that stores a partition function value.
 
typedef std::list< Interaction > InteractionList
 list of interactions
 
typedef boost::unordered_map< Interaction::BasePair, BestInteractionE, Interaction::BasePair::Hash > HashIdx2E
 hash to map index pairs to BestInteractionE entries
 
- Protected Attributes inherited from IntaRNA::PredictorMfe
InteractionList mfeInteractions
 mfe interaction boundaries
 
HashIdx2E mfe4leftEnd
 
std::pair< IndexRangeList, IndexRangeList > reportedInteractions
 
InteractionEnergyIdxOffset energy
 access to the interaction energy handler of the super class
 
OutputHandler & output
 access to the output handler of the super class
 
PredictionTracker * predTracker
 access to the prediction tracker of the super class
 
- Protected Attributes inherited from IntaRNA::Predictor
InteractionEnergyIdxOffset energy
 energy computation handler
 
OutputHandler & output
 interaction output handler
 
PredictionTracker * predTracker
 prediction tracker to be used
 
Z_type Zall
 

Detailed Description

Deterministic, strictly downhill extension of every feasible seed.

At each step both ends compete using the complete interaction-energy difference, including accessibility, terminal penalties and both weighted dangling ends. Score A uses this difference directly; B divides by 1+s1+s2; C (C1) divides by 1+2*max(s1,s2). These are heuristic move rankings, not physical rates or a calibrated folding-time model. Only negative energy differences are accepted, including for the normalized scores.

Extensions always add one stacked pair or two stacked pairs, including across a loop. Seeds and their energies are trusted as supplied by the seed handler, even when an explicit seed contains lonely pairs. Ties prefer left, smaller s1+s2, smaller s1, then the single-pair move. Every valid visited prefix is eligible for normal MFE/suboptimal reporting; traceback reproduces the actual greedy path. Equilibrium partition-function output is unsupported.

Candidate enumeration uses the active energy model and separate loop/span limits for both RNAs. Every feasible move is evaluated with its complete energy change.

Constructor & Destructor Documentation

◆ PredictorSeedExtensionKinetic()

IntaRNA::PredictorSeedExtensionKinetic::PredictorSeedExtensionKinetic ( const InteractionEnergy &  energy,
OutputHandler &  output,
PredictionTracker *  predTracker,
SeedHandler *  seedHandler,
const char  score = 'A' 
)

Constructs a predictor, taking ownership of tracker and seed handler.

Parameters
energyenergy model, which must outlive this predictor
outputoutput handler, which must outlive this predictor
predTrackerowned tracker, or NULL
seedHandlerowned, non-NULL seed handler
scoremove ranking: A, B, or C (the C1 formula)
Exceptions
std::invalid_argumentfor a NULL seed handler, unknown score or output requiring an equilibrium partition function

◆ ~PredictorSeedExtensionKinetic()

virtual IntaRNA::PredictorSeedExtensionKinetic::~PredictorSeedExtensionKinetic ( )
virtual

Frees the owned seed handler and prediction tracker.

Member Function Documentation

◆ getNextBest()

void IntaRNA::PredictorSeedExtensionKinetic::getNextBest ( Interaction &  interaction)
overrideprotectedvirtual

Finds the best cached prefix disjoint from already reported intervals.

Parameters
interactioncurrent report, replaced by the next report or E_INF

Reimplemented from IntaRNA::PredictorMfe.

◆ predict()

void IntaRNA::PredictorSeedExtensionKinetic::predict ( const IndexRange &  r1 = IndexRange(0, RnaSequence::lastPos),
const IndexRange &  r2 = IndexRange(0, RnaSequence::lastPos) 
)
overridevirtual

Extends all feasible seeds within inclusive, zero-based sequence ranges. Sequence 2 uses the reversed indexing of the energy model. Repeated calls reset all trajectories, cached output and index offsets.

Parameters
r1permitted range in sequence 1
r2permitted range in reversed sequence 2
Exceptions
std::invalid_argumentfor an invalid or empty input range

Implements IntaRNA::Predictor.

◆ traceBack()

void IntaRNA::PredictorSeedExtensionKinetic::traceBack ( Interaction &  interaction)
overrideprotectedvirtual

Restores the exact stored greedy path and annotates its contained seeds.

Parameters
interactioninteraction boundaries to expand

Implements IntaRNA::PredictorMfe.


The documentation for this class was generated from the following file: