[R] Add a compatibility layer to load Booster object from an old RDS file (#5940)
* [R] Add a compatibility layer to load Booster from an old RDS * Modify QuantileHistMaker::LoadConfig() to be backward compatible with 1.1.x * Add a big warning about compatibility in QuantileHistMaker::LoadConfig() * Add testing suite * Discourage use of saveRDS() in CRAN doc
This commit is contained in:
committed by
GitHub
parent
40361043ae
commit
ace7fd328b
15
R-package/man/a-compatibility-note-for-saveRDS.Rd
Normal file
15
R-package/man/a-compatibility-note-for-saveRDS.Rd
Normal file
@@ -0,0 +1,15 @@
|
||||
% Generated by roxygen2: do not edit by hand
|
||||
% Please edit documentation in R/utils.R
|
||||
\name{a-compatibility-note-for-saveRDS}
|
||||
\alias{a-compatibility-note-for-saveRDS}
|
||||
\title{Do not use saveRDS() for long-term archival of models. Use xgb.save() instead.}
|
||||
\description{
|
||||
It is a common practice to use the built-in \code{saveRDS()} function to persist R objects to
|
||||
the disk. While \code{xgb.Booster} objects can be persisted with \code{saveRDS()} as well, it
|
||||
is not advisable to use it if the model is to be accessed in the future. If you train a model
|
||||
with the current version of XGBoost and persist it with \code{saveRDS()}, the model is not
|
||||
guaranteed to be accessible in later releases of XGBoost. To ensure that your model can be
|
||||
accessed in future releases of XGBoost, use \code{xgb.save()} instead. For more details and
|
||||
explanation, consult the page
|
||||
\url{https://xgboost.readthedocs.io/en/latest/tutorials/saving_model.html}.
|
||||
}
|
||||
Reference in New Issue
Block a user