NVIDIA-Merlin / models

Merlin Models is a collection of deep learning recommender system model reference implementations
https://nvidia-merlin.github.io/models/main/index.html
Apache License 2.0
262 stars 50 forks source link

[QST] How to use negative sampling with ranking models ? #1229

Open PaulSteffen-betclic opened 1 year ago

PaulSteffen-betclic commented 1 year ago

❓ Questions & Help

Details

I have a dataset with only positive implicit feedbacks and I would like to train a ranking model on these data. How to use negative sampling with ranking models ? Thanks.

sararb commented 4 months ago

We have a class, called InBatchNegatives, where the positive samples within a batch are used as negative samples. You can check this page for the unit tests.