Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

randomForest hangs when nodesize >= sampsize #1557

Closed
mb706 opened this issue Feb 26, 2017 · 5 comments
Closed

randomForest hangs when nodesize >= sampsize #1557

mb706 opened this issue Feb 26, 2017 · 5 comments

Comments

@mb706
Copy link
Contributor

mb706 commented Feb 26, 2017

If the nodesize parameter (either given, or default 5 for regression and 1 for classification) exceeds (edit: or equals) the sampsize parameter (either given, or defaulting to if (replace) nrow(x) else ceiling(0.632 * nrow(x))), classif.randomForest and regr.randomForest hang and can no longer be interrupted with Ctrl-C.

> resample(makeLearner("regr.randomForest", sampsize=2, nodesize=3), pid.task, hout)
[Resample] holdout iter 1:    

I don't know if this should be mlr's responsibility; in principle, the trainLearner code could check for this and throw an error. Please tell me if these kind of bugs don't belong here.

@larskotthoff
Copy link
Member

Hmm, we should be able to do this when #1126 is merged I think. And yes, certainly a good thing to raise here.

@mb706 mb706 changed the title randomForest hangs when nodesize > sampsize randomForest hangs when nodesize >= sampsize Feb 27, 2017
@berndbischl
Copy link
Member

. Please tell me if these kind of bugs don't belong here.

i really do not think that we want to maintain all of these special cases in mlr?
and if the learner hangs that seems like a really bad bug in the package - which you should take up with the original package author

@larskotthoff
Copy link
Member

But in this case it makes sense to check this in mlr. I agree that the learner hanging is a bug, but even if it didn't it wouldn't make sense.

@jakob-r
Copy link
Member

jakob-r commented Feb 27, 2017

But then still - in the very end randomForest should throw a useful error message.

@stale
Copy link

stale bot commented Dec 19, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 19, 2019
@stale stale bot closed this as completed Dec 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants