Skip to content

[MRG] Remove redundant logic in Decision Tree - #7340

Closed
nelson-liu wants to merge 2 commits into
scikit-learn:masterfrom
nelson-liu:remove_tree_redundant_logic
Closed

nelson-liu wants to merge 2 commits into
scikit-learn:masterfrom
nelson-liu:remove_tree_redundant_logic

Conversation

@nelson-liu

Copy link
Copy Markdown
Contributor

Reference Issue

Fixes #7338

What does this implement/fix? Explain your changes.

Removes duplicate logic in tree building and edits min_samples_leaf to behave similarly to min_fraction_weight_leaf. Also removes automatic setting of min_samples_split from min_samples_split.

Any other comments?

A PR with the concrete changes proposed in #7338

@nelson-liu nelson-liu changed the title Remove tree redundant logic [MRG] Remove tree redundant logic Sep 4, 2016
@nelson-liu nelson-liu changed the title [MRG] Remove tree redundant logic [MRG] Remove redundant logic in Decision Tree Sep 4, 2016
Comment thread sklearn/tree/tree.py
If None then unlimited number of leaf nodes.

class_weight : dict, list of dicts, "balanced" or None, optional (default=None)
class_weight : dict, list of dicts, "balanced" or None, \

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This renders correctly, but is there a better way to do it?

@jnothman

jnothman commented Sep 5, 2016

Copy link
Copy Markdown
Member

I'm closing this PR, then...?

@jnothman jnothman closed this Sep 5, 2016
@jnothman

jnothman commented Sep 5, 2016

Copy link
Copy Markdown
Member

Or do you hope to remove that unused condition here?

@nelson-liu

Copy link
Copy Markdown
Contributor Author

I figure this might be a good place to do it.. I'm also fine with working in private a bit then opening a new PR.

By not working, you mean giving different results?

Yes, exactly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Duplicate logic in Decision Tree Building

2 participants