Mantid
Loading...
Searching...
No Matches
Static Public Member Functions | List of all members
Mantid::PythonInterface::Converters::Clone::apply< ElementType > Struct Template Reference

#include <CloneToNDArray.h>

Static Public Member Functions

static PyObject * create1D (const std::vector< ElementType > &cvector)
 Returns a Numpy array that has a copy of the vectors data. More...
 
static PyObject * createFromArray (const ElementType *carray, const int ndims, Py_intptr_t *dims)
 Returns a Numpy array that has a copy of the array data. More...
 

Detailed Description

template<typename ElementType>
struct Mantid::PythonInterface::Converters::Clone::apply< ElementType >

Definition at line 27 of file CloneToNDArray.h.

Member Function Documentation

◆ create1D()

template<typename ElementType >
static PyObject * Mantid::PythonInterface::Converters::Clone::apply< ElementType >::create1D ( const std::vector< ElementType > &  cvector)
inlinestatic

Returns a Numpy array that has a copy of the vectors data.

Parameters
cvectorAn object that knows its length and is contiguous in memory
Returns

Definition at line 34 of file CloneToNDArray.h.

◆ createFromArray()

template<typename ElementType >
static PyObject * Mantid::PythonInterface::Converters::Clone::apply< ElementType >::createFromArray ( const ElementType *  carray,
const int  ndims,
Py_intptr_t *  dims 
)
inlinestatic

Returns a Numpy array that has a copy of the array data.

Parameters
carray:: The input data array
ndims:: The number of dimensions the data represents
dims:: The extents in each of the dimensions
Returns

Definition at line 42 of file CloneToNDArray.h.


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