Skip to content

Commit

Permalink
Replace deprecated function in Python layer (#487)
Browse files Browse the repository at this point in the history
  • Loading branch information
hcho3 authored May 2, 2023
1 parent af74664 commit 4e30fad
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion python/treelite/frontend.py
Original file line number Diff line number Diff line change
Expand Up @@ -539,8 +539,9 @@ def from_lightgbm(cls, booster):
if not isinstance(booster, lightgbm.Booster):
raise ValueError('booster must be of type `lightgbm.Booster`')
model_str = booster.model_to_string()
_check_call(_LIB.TreeliteLoadLightGBMModelFromString(
_check_call(_LIB.TreeliteLoadLightGBMModelFromStringEx(
c_str(model_str),
c_str("{}"),
ctypes.byref(handle)))
return Model(handle)

Expand Down

0 comments on commit 4e30fad

Please sign in to comment.