scikit-learn/scikit-learn — pull request #2977 by arjoly (2014-03-20 13:14:23+00:00)
Title: Some cleanup in _tree.pyx

This pr clean up the _tree module:

- Avoid storing tree parameter in `Tree`, instead pass those parameters directly to `TreeBuilder`
- Avoid storing the `random_state` in `Tree`.
- Split `CONSTANT_FEATURE_THRESHOLD` into two constants `MIN_IMPURITY_SPLIT ` and `CONSTANT_FEATURE_THRESHOLD`.
- Stricter separation between the TreeBuilder, splitter and the criterion.
- Add stopping criterion `MIN_IMPURITY_SPLIT ` to `BestFirstTreeBuilder` as to be symmetric with `DepthFirstTreeBuilder`.
- Fix pep8 error

This pr is ready for review.

Should we kept the `CONSTANT_FEATURE_THRESHOLD` feature? It could lead to unexpected behaviour to users.