X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FMEDCoupling_Swig%2FMEDCouplingRemapper.i;h=10d9f9b382be398854d1936d3aec571a1b07b7b4;hb=f91f8722f2850de4eb9b03961e86c634386fa328;hp=489c9e56515e00516eaefc189a6ddbcc34a0dff9;hpb=0511285d155a0682ff6dad10ac916ac53f577476;p=tools%2Fmedcoupling.git diff --git a/src/MEDCoupling_Swig/MEDCouplingRemapper.i b/src/MEDCoupling_Swig/MEDCouplingRemapper.i index 489c9e565..10d9f9b38 100644 --- a/src/MEDCoupling_Swig/MEDCouplingRemapper.i +++ b/src/MEDCoupling_Swig/MEDCouplingRemapper.i @@ -1,9 +1,9 @@ -// Copyright (C) 2007-2012 CEA/DEN, EDF R&D +// Copyright (C) 2007-2014 CEA/DEN, EDF R&D // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation; either -// version 2.1 of the License. +// version 2.1 of the License, or (at your option) any later version. // // This library is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -57,7 +57,7 @@ namespace ParaMEDMEM public: MEDCouplingRemapper(); ~MEDCouplingRemapper(); - int prepare(const MEDCouplingMesh *srcMesh, const MEDCouplingMesh *targetMesh, const char *method) throw(INTERP_KERNEL::Exception); + int prepare(const MEDCouplingMesh *srcMesh, const MEDCouplingMesh *targetMesh, const std::string& method) throw(INTERP_KERNEL::Exception); int prepareEx(const MEDCouplingFieldTemplate *src, const MEDCouplingFieldTemplate *target) throw(INTERP_KERNEL::Exception); void transfer(const MEDCouplingFieldDouble *srcField, MEDCouplingFieldDouble *targetField, double dftValue) throw(INTERP_KERNEL::Exception); void partialTransfer(const MEDCouplingFieldDouble *srcField, MEDCouplingFieldDouble *targetField) throw(INTERP_KERNEL::Exception); @@ -73,6 +73,8 @@ namespace ParaMEDMEM int nullifiedTinyCoeffInCrudeMatrixAbs(double maxValAbs) throw(INTERP_KERNEL::Exception); int nullifiedTinyCoeffInCrudeMatrix(double scaleFactor) throw(INTERP_KERNEL::Exception); double getMaxValueInCrudeMatrix() const throw(INTERP_KERNEL::Exception); + int getNumberOfColsOfMatrix() const throw(INTERP_KERNEL::Exception); + static std::string BuildMethodFrom(const std::string& meth1, const std::string& meth2) throw(INTERP_KERNEL::Exception); %extend { PyObject *getCrudeMatrix() const throw(INTERP_KERNEL::Exception) @@ -90,6 +92,12 @@ namespace ParaMEDMEM } return ret; } +#if defined(WITH_NUMPY) && defined(WITH_SCIPY) + PyObject *getCrudeCSRMatrix() const throw(INTERP_KERNEL::Exception) + { + return ToCSRMatrix(self->getCrudeMatrix(),self->getNumberOfColsOfMatrix()); + } +#endif } }; } @@ -107,6 +115,9 @@ def ParaMEDMEMDataArrayDoubleImul(self,*args): def ParaMEDMEMDataArrayDoubleIdiv(self,*args): import _MEDCouplingRemapper return _MEDCouplingRemapper.DataArrayDouble____idiv___(self, self, *args) +def ParaMEDMEMDataArrayDoubleIpow(self,*args): + import _MEDCouplingRemapper + return _MEDCouplingRemapper.DataArrayDouble____ipow___(self, self, *args) def ParaMEDMEMMEDCouplingFieldDoubleIadd(self,*args): import _MEDCouplingRemapper return _MEDCouplingRemapper.MEDCouplingFieldDouble____iadd___(self, self, *args) @@ -119,6 +130,9 @@ def ParaMEDMEMMEDCouplingFieldDoubleImul(self,*args): def ParaMEDMEMMEDCouplingFieldDoubleIdiv(self,*args): import _MEDCouplingRemapper return _MEDCouplingRemapper.MEDCouplingFieldDouble____idiv___(self, self, *args) +def ParaMEDMEMMEDCouplingFieldDoubleIpow(self,*args): + import _MEDCouplingRemapper + return _MEDCouplingRemapper.MEDCouplingFieldDouble____ipow___(self, self, *args) def ParaMEDMEMDataArrayIntIadd(self,*args): import _MEDCouplingRemapper return _MEDCouplingRemapper.DataArrayInt____iadd___(self, self, *args) @@ -134,6 +148,9 @@ def ParaMEDMEMDataArrayIntIdiv(self,*args): def ParaMEDMEMDataArrayIntImod(self,*args): import _MEDCouplingRemapper return _MEDCouplingRemapper.DataArrayInt____imod___(self, self, *args) +def ParaMEDMEMDataArrayIntIpow(self,*args): + import _MEDCouplingRemapper + return _MEDCouplingRemapper.DataArrayInt____ipow___(self, self, *args) def ParaMEDMEMDataArrayDoubleTupleIadd(self,*args): import _MEDCouplingRemapper return _MEDCouplingRemapper.DataArrayDoubleTuple____iadd___(self, self, *args) @@ -161,6 +178,12 @@ def ParaMEDMEMDataArrayIntTupleIdiv(self,*args): def ParaMEDMEMDataArrayIntTupleImod(self,*args): import _MEDCouplingRemapper return _MEDCouplingRemapper.DataArrayIntTuple____imod___(self, self, *args) +def ParaMEDMEMDenseMatrixIadd(self,*args): + import _MEDCouplingRemapper + return _MEDCouplingRemapper.DenseMatrix____iadd___(self, self, *args) +def ParaMEDMEMDenseMatrixIsub(self,*args): + import _MEDCouplingRemapper + return _MEDCouplingRemapper.DenseMatrix____isub___(self, self, *args) %} %include "MEDCouplingFinalize.i"