Dip 0.95.0
Loading...
Searching...
No Matches
DippyAlgoMixin Class Reference

Mixin class for Dip Algorithms. More...

#include <DippyDecompAlgo.h>

+ Inheritance diagram for DippyAlgoMixin:
+ Collaboration diagram for DippyAlgoMixin:

Public Member Functions

 DippyAlgoMixin (UtilParameters &utilParam, PyObject *pProb)
 Constructor.
 
bool chooseBranchSet (DecompAlgo *algo, std::vector< std::pair< int, double > > &downBranchLB, std::vector< std::pair< int, double > > &downBranchUB, std::vector< std::pair< int, double > > &upBranchLB, std::vector< std::pair< int, double > > &upBranchUB)
 
PyObject * getPDownLB ()
 
PyObject * getPDownUB ()
 
PyObject * getPUpLB ()
 
PyObject * getPpUpUB ()
 
void postProcessBranch (DecompAlgo *algo, DecompStatus decompStatus)
 
void postProcessNode (DecompAlgo *algo, DecompStatus decompStatus)
 

Protected Attributes

PyObject * m_pProb
 
UtilParametersm_utilParam
 

Detailed Description

Mixin class for Dip Algorithms.

This is a helper class for interfacing Dip Algo classes with Python. To add Python support to a standard DecompAlgo, create a subclass which also inherits from DippyAlgoMixin and override the virtual methods to call those provided by the Mixin class. See DippyAlgoC for an example.

Definition at line 22 of file DippyDecompAlgo.h.

Constructor & Destructor Documentation

◆ DippyAlgoMixin()

DippyAlgoMixin::DippyAlgoMixin ( UtilParameters & utilParam,
PyObject * pProb )
inline

Constructor.

Parameters
utilParamparameter class
pProba DipProblem python object

Definition at line 39 of file DippyDecompAlgo.h.

Member Function Documentation

◆ chooseBranchSet()

bool DippyAlgoMixin::chooseBranchSet ( DecompAlgo * algo,
std::vector< std::pair< int, double > > & downBranchLB,
std::vector< std::pair< int, double > > & downBranchUB,
std::vector< std::pair< int, double > > & upBranchLB,
std::vector< std::pair< int, double > > & upBranchUB )

◆ getPDownLB()

PyObject * DippyAlgoMixin::getPDownLB ( )
inline

Definition at line 50 of file DippyDecompAlgo.h.

◆ getPDownUB()

PyObject * DippyAlgoMixin::getPDownUB ( )
inline

Definition at line 53 of file DippyDecompAlgo.h.

◆ getPUpLB()

PyObject * DippyAlgoMixin::getPUpLB ( )
inline

Definition at line 56 of file DippyDecompAlgo.h.

◆ getPpUpUB()

PyObject * DippyAlgoMixin::getPpUpUB ( )
inline

Definition at line 59 of file DippyDecompAlgo.h.

◆ postProcessBranch()

void DippyAlgoMixin::postProcessBranch ( DecompAlgo * algo,
DecompStatus decompStatus )

◆ postProcessNode()

void DippyAlgoMixin::postProcessNode ( DecompAlgo * algo,
DecompStatus decompStatus )

Member Data Documentation

◆ m_pProb

PyObject* DippyAlgoMixin::m_pProb
protected

Definition at line 30 of file DippyDecompAlgo.h.

◆ m_utilParam

UtilParameters* DippyAlgoMixin::m_utilParam
protected

Definition at line 31 of file DippyDecompAlgo.h.


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