23 #include <pybind11/pybind11.h> 25 #include <pybind11/stl.h> 29 namespace py = pybind11;
33 template <
typename ReturnT>
36 std::vector<double>
const &, std::vector<double>
const &,
37 std::vector<double>
const &, std::vector<double>
const &,
38 std::vector<double>
const &,
double))minimize<ReturnT>);
41 std::vector<double>
const &, std::vector<double>
const &,
42 std::vector<double>
const &, std::vector<double>
const &,
43 std::vector<double>
const &,
double))minimize<ReturnT>);
47 py::module mod(
"_minimize",
"Python wrapper for afw _minimize library");
58 py::class_<FitResults> clsFitResults(mod,
"FitResults");
64 declareMinimize<double>(mod);
65 declareMinimize<float>(mod);
std::vector< double > parameterList
fit parameters
std::vector< std::pair< double, double > > parameterErrorList
negative,positive (1 sigma?) error for each parameter
A Function taking two arguments.
Results from minimizing a function.
double chiSq
chi squared; may be nan or infinite, but only if isValid false
A Function taking one argument.
bool isValid
true if the fit converged; false otherwise
void declareMinimize(py::module &mod)
PYBIND11_PLUGIN(_approximate)