Assert desc.level > 0 removed
The assert was checking that leaf node can not be a root node.
Well, it can for a degenerate tree consisting of a single node.
Such a tree is constructed in scikit-learn example fit_2d_1sample.
@@ -252,7 +252,6 @@ bool toSKLearnTreeObjectVisitor<M>::onLeafNode(const typename TNVT<M>::leaf_desc
template<typename M>
bool toSKLearnTreeObjectVisitor<M>::_onLeafNode(const daal::algorithms::tree_utils::NodeDescriptor &desc)
{
- assert(desc.level > 0);
if(desc.level) {
ssize_t parent = parents[desc.level - 1];
