From ad4e8bd8e3106ca753d63b3969bf3794fddcc5ac Mon Sep 17 00:00:00 2001 From: Michael BAUDIN Date: Tue, 18 Jun 2024 19:58:29 +0200 Subject: [PATCH] Fixed BoxCoxFactory --- .../ProcessTransformation/openturns/BoxCoxFactory.hxx | 4 ++-- python/src/BoxCoxFactory.i | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/src/Uncertainty/Algorithm/Transformation/ProcessTransformation/openturns/BoxCoxFactory.hxx b/lib/src/Uncertainty/Algorithm/Transformation/ProcessTransformation/openturns/BoxCoxFactory.hxx index f09fb01587..e15eef76e0 100644 --- a/lib/src/Uncertainty/Algorithm/Transformation/ProcessTransformation/openturns/BoxCoxFactory.hxx +++ b/lib/src/Uncertainty/Algorithm/Transformation/ProcessTransformation/openturns/BoxCoxFactory.hxx @@ -96,12 +96,12 @@ public: const Sample &outputSample, const Basis &basis, const Point &shift, - LinearModelResult &linearModelResult); + LinearModelResult & linearModelResultOut); BoxCoxTransform buildWithLM(const Sample &inputSample, const Sample &outputSample, const Point &shift, - LinearModelResult &linearModelResult); + LinearModelResult & linearModelResultOut); /** Optimization solver accessor */ OptimizationAlgorithm getOptimizationAlgorithm() const; diff --git a/python/src/BoxCoxFactory.i b/python/src/BoxCoxFactory.i index 6aac6f38c9..544acc70ea 100644 --- a/python/src/BoxCoxFactory.i +++ b/python/src/BoxCoxFactory.i @@ -1,8 +1,8 @@ // SWIG file BoxCoxFactory.i // do not pass argument by reference, return it as tuple item -%typemap(in, numinputs=0) OT::LinearModelResult & linearModelResult ($*ltype temp) %{ temp = OT::LinearModelResult(); $1 = &temp; %} -%typemap(argout) OT::LinearModelResult & linearModelResult %{ $result = SWIG_Python_AppendOutput($result, SWIG_NewPointerObj(new OT::LinearModelResult(*$1), SWIGTYPE_p_OT__LinearModelResult, SWIG_POINTER_OWN | 0 )); %} +%typemap(in, numinputs=0) OT::LinearModelResult & linearModelResultOut ($*ltype temp) %{ temp = OT::LinearModelResult(); $1 = &temp; %} +%typemap(argout) OT::LinearModelResult & linearModelResultOut %{ $result = SWIG_Python_AppendOutput($result, SWIG_NewPointerObj(new OT::LinearModelResult(*$1), SWIGTYPE_p_OT__LinearModelResult, SWIG_POINTER_OWN | 0 )); %} %typemap(in, numinputs=0) OT::GeneralLinearModelResult & generalLinearModelResult ($*ltype temp) %{ temp = OT::GeneralLinearModelResult(); $1 = &temp; %} %typemap(argout) OT::GeneralLinearModelResult & generalLinearModelResult %{ $result = SWIG_Python_AppendOutput($result, SWIG_NewPointerObj(new OT::GeneralLinearModelResult(*$1), SWIGTYPE_p_OT__GeneralLinearModelResult, SWIG_POINTER_OWN | 0 )); %}