-
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
[python-package] Passing non-serializable loss function since 4.0.0. #6056
Comments
Can you please share the function definition and a minimal, reproducible example showing how you're using it and the error you're getting? |
@jameslamb
Output:
For 3.3.5 we can change Obviously this example makes no sense. In practice I'm synchronizing loss calculation of multiple boosters so they can share multi-variable loss through the wrapper. |
Hello. I have custom non-serializable loss function which I was passing through
fobj
param oflgb.train()
.Since #5052 it's not possible any more.
Also it's not possible to pass non-serializable loss function as
params['fobj']
value, because of multiplecopy.deepcopy(params)
usages intrain()
function.So what is the way to pass such loss function in 4.0.0?
The text was updated successfully, but these errors were encountered: