[c++] Fixed Predictor lifecycle and trees initialization in Contrib mode#6778
[c++] Fixed Predictor lifecycle and trees initialization in Contrib mode#6778StrikerRUS merged 5 commits intomicrosoft:masterfrom
Conversation
2) Fixed Boosting trees initialization microsoft#5482
jameslamb
left a comment
There was a problem hiding this comment.
Thanks for this! Will defer to other reviewers with more C++ experience but one question... is it possible to test that correctness of this by adding test cases in https://github.com/microsoft/LightGBM/tree/master/tests/cpp_tests?
There are tests on prediction there, but I specifically mean testing that this previously-not-thread-safe behavior remains thread-safe.
That'd reduce the risk of issues be re-introduced in future refactorings.
|
@jameslamb, I've tried to. Unfortunately, the tests fail (not my tests, I reverted my changes ensure that it's not my code). Where should I add the test? In test_single_row.cpp ? |
|
Ah interesting. Looking at that error, I suspect the issue is the working directory you're running from. That test has hard-coded relative paths from the root of the repo, so the Here's how we run the tests in continuous integration: Lines 61 to 63 in e0c34e7
Yep that seems like a good place, thanks! |
|
/gha run r-valgrind Workflow R valgrind tests has been triggered! 🚀 Status: success ✔️. |
|
Is there anything else I should do to push the PR? |
jameslamb
left a comment
There was a problem hiding this comment.
I have no other comments. Hoping @shiyu1994 or @guolinke can review this when they have time.
|
@shiyu1994, @guolinke Could you review the PR? |
StrikerRUS
left a comment
There was a problem hiding this comment.
LGTM, thanks a lot for your PR!
|
This pull request has been automatically locked since there has not been any recent activity since it was closed. |









Fixed #5482