strip_to_rank default is `False`
Created by: anjos
As it is encoded today, despite the C++ class defaults to a True
value for this setting, the Python bindings override it with a default False
.
The problem is on these bindings piece of code:
PyObject* strip_to_rank = Py_True;
if (!PyArg_ParseTupleAndKeywords(args, kwds, "|OO", kwlist,
&use_pinv, &strip_to_rank)) return -1;
int use_pinv_ = PyObject_IsTrue(use_pinv);
if (use_pinv_ == -1) return -1;
int strip_to_rank_ = PyObject_IsTrue(strip_to_rank);
if (strip_to_rank_ == -1) return -1;
self->cxx = new bob::learn::linear::FisherLDATrainer(use_pinv_, strip_to_rank_);
If strip_to_rank
is not set, it defaults to Py_None
, which does not resolve to True
, but False
.