1 #ifndef DIPPY_PYTHONUTILS_INCLUDED
2 #define DIPPY_PYTHONUTILS_INCLUDED
7 #include "DecompAlgo.h"
64 map<PyObject*, int> rowIndices, map<PyObject*, int> colIndices);
74 void insertTupleToPyList(PyObject* pList,
unsigned position, PyObject* key, PyObject* value);
void addTupleToPyList(PyObject *pList, PyObject *key, PyObject *value)
Creates a (key,value) tuple and appends to a Python list of tuples *.
Sparse Matrix Base Class.
void pyColDict_AsPairedVector(PyObject *pColDict, vector< pair< int, double > > &vector, map< PyObject *, int > indices)
Convert a column dictionary to a (int, double) vector.
CoinPackedMatrix * pyConstraints_AsPackedMatrix(PyObject *pRowList, map< PyObject *, int > rowIndices, map< PyObject *, int > colIndices)
Convert a list of Python constraints to a CoinPackedMatrix.
PyObject * pyTupleList_FromDoubleArray(const double *values, PyObject *pList)
Convert a double array to a Python tuple list.
int pyColDict_AsPackedArrays(PyObject *pColDict, map< PyObject *, int > indices, int **inds, double **vals)
Convert a column dictionary to packed arrays.
void insertTupleToPyList(PyObject *pList, unsigned position, PyObject *key, PyObject *value)
Creates a (key,value) tuple and inserts in a Python list of tuples *.
PyObject * pyTupleList_FromNode(DecompAlgo *algo, DecompStatus decompStatus)
Package a AlpsDecompTreeNode using a DecompAlgo into a Python list.
Base class for DECOMP algorithms.