Skip to content
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

The difference ranking result in the python and libcatboost by max_relevance times #2612

Open
akalend opened this issue Mar 14, 2024 · 1 comment

Comments

@akalend
Copy link

akalend commented Mar 14, 2024

Problem:
The difference result of the rank model in the python and libcatboost
Разные результаты при работе модели в python и си кода с использованием libcatboost. Отличаются на величину max_relevance

Steps of problem:

  1. I use the training model from tutorial https://github.com/catboost/tutorials/tree/master/ranking

  2. The url of my notebook of the model is https://colab.research.google.com/drive/1IXzicNub6CtzPRW3ZUfFkud48EDgaLhC?usp=sharing

  3. The RMSE criterion was used.

  4. The model saved as cbm format and use in the C-code. The example of code : https://github.com/cyrusmsk/tutorials/tree/clang_dlang_applier_tutorials/apply_model/clang

  5. compare results from Python and C-code (libcatboost) : the results differ by max_relevance times (4 times) . See cell number 29 in the notebook (Itemt 2).

The original C-code https://github.com/akalend/pg_ml/blob/main/ml.c

catboost version: catboost-1.2.3-cp310-cp310-manylinux2014_x86_64.whl ( Google collab)
Operating System: Ubuntu 20.0
CPU: iCore i5 local machine

@akalend akalend changed the title The difference ranking result in the python and libcatboost The difference ranking result in the python and libcatboost by max_relevance times Mar 14, 2024
@andrey-khropov
Copy link
Member

I cannot reproduce this.

See the training code in python and inference code in C++. In my example they produce the same predictions.
I tried both single-object and multi-objects variants.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants