-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
[R-package] remove Dataset setinfo() #4854
Conversation
@@ -227,13 +227,7 @@ Run ``lgb.unloader(wipe = TRUE)`` in the R console, and recreate the LightGBM da | |||
Due to the pointers, choosing to not wipe variables will not fix the error. | |||
This is a known issue: `Microsoft/LightGBM#698 <https://github.com/microsoft/LightGBM/issues/698>`__. | |||
|
|||
2. I used ``setinfo()``, tried to print my ``lgb.Dataset``, and now the R console froze! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't break references to this FAQ used at third-party sites. Just replace the answer for this question with info about that this is not actual anymore. Refer to https://github.com/microsoft/LightGBM/blob/master/docs/FAQ.rst#1-error-setup-script-specifies-an-absolute-path-when-installing-from-github-using-python-setuppy-install or https://github.com/microsoft/LightGBM/blob/master/docs/FAQ.rst#6-bagging-is-not-reproducible-when-changing-the-number-of-threads as an example.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah ok, yes I agree with you. Fixed in 0770c94.
I checked on v3.3.0 and latest master
, and there are no longer issues printing a Dataset (maybe as a result of work in #3016 ).
library(lightgbm)
data(agaricus.train, package = "lightgbm")
train <- agaricus.train
dtrain <- lgb.Dataset(train$data, label = train$label)
print(dtrain)
dtrain$construct()
print(dtrain)
dtrain$setinfo("weight", rep(1.0, nrow(train$data)))
print(dtrain)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Nice to see this cleanup!
This pull request has been automatically locked since there has not been any recent activity since it was closed. To start a new related discussion, open a new issue at https://github.com/microsoft/LightGBM/issues including a reference to this. |
Contributes to #4543.
This PR proposes removing
Dataset$setinfo()
and the corresponding S3 method. See #4543 for background on why.Notes for Reviewers
v3.3.0 and v3.3.1 contain a deprecation warning about this change.