Hello I'm trying to change the entropy function which is used in sklearn for DecisionTreeClassification locally on my system. when I rerun the pip install --editable . command after updating the cython file, I receive the following error message:
Error compiling Cython file: ------------------------------------------------------------ ... for k in range(self.n_outputs): for c in range(n_classes[k]): count_k = sum_total[c] if count_k > 0.0: count_k /= self.weighted_n_node_samples entropy -= count_k * np.log2(count_k) ^ ------------------------------------------------------------ sklearn/tree/_criterion.pyx:537:20: Coercion from Python not allowed without the GIL This error is persisten with other errors as: Operation not allowed without gil Converting to Python object not allowed without gil Converting to Python object not allowed without gil Calling gil-requiring function not allowed without gil Accessing Python attribute not allowed without gil Accessing Python global or builtin not allowed without gil I've tried looking up for solution on various sites, but could not resolve the issue. Any help would be appreciated. Thanks and regards Aditya Aggarwal
_______________________________________________ scikit-learn mailing list scikit-learn@python.org https://mail.python.org/mailman/listinfo/scikit-learn