ray.train.lightgbm.LightGBMCheckpoint
ray.train.lightgbm.LightGBMCheckpoint#
- class ray.train.lightgbm.LightGBMCheckpoint(local_path: Optional[Union[str, os.PathLike]] = None, data_dict: Optional[dict] = None, uri: Optional[str] = None)[source]#
Bases:
ray.air.checkpoint.CheckpointA
Checkpointwith LightGBM-specific functionality.Create this from a generic
Checkpointby callingLightGBMCheckpoint.from_checkpoint(ckpt).PublicAPI (beta): This API is in beta and may change before becoming stable.
Methods
__init__([local_path, data_dict, uri])DeveloperAPI: This API may change across minor Ray releases.
Return checkpoint directory path in a context.
from_bytes(data)Create a checkpoint from the given byte string.
from_checkpoint(other)Create a checkpoint from a generic
ray.air.checkpoint.Checkpoint.from_dict(data)Create checkpoint object from dictionary.
from_directory(path)Create checkpoint object from directory.
from_model(booster, *[, preprocessor])Create a
Checkpointthat stores a LightGBM model.from_uri(uri)Create checkpoint object from location URI (e.g.
Return tuple of (type, data) for the internal representation.
Retrieve the LightGBM model stored in this checkpoint.
Return the saved preprocessor, if one exists.
set_preprocessor(preprocessor)Saves the provided preprocessor to this Checkpoint.
to_bytes()Return Checkpoint serialized as bytes object.
to_dict()Return checkpoint data as dictionary.
to_directory([path])Write checkpoint data to directory.
to_uri(uri)Write checkpoint data to location URI (e.g.
Attributes
Return path to checkpoint, if available.
Return checkpoint URI, if available.