lyst / lyst/lightfm

Excluding some negatives from training

Open
#637 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
5.1k
Forks
724
PR merge metrics
No merged PRs in 30d

Description

Hi!

First of all, thank you for this great library!

I'm currently using it for extending and comparing some matrix factorisation models for recommendation. I am working on the [LFM-2b dataset](http://www.cp.jku.at/datasets/LFM-2b/).

For design reasons, part of my interaction matrix (or rather an extended version of it) consists of a block of zeros, which however should NOT be considered while training. In other words, if we imagine to be using either BPR or WARP, the negative samples should never belong to this block.

To explain things better, I want to train on a matrix like this:
![inter_matrix](https://user-images.githubusercontent.com/33102386/157886512-5ff3555c-9445-4240-85a0-443f28d10731.png)
with **A, B, C** being sparse matrices and **0** being an empty matrix. The model should NOT use the entries of the bottom-right block for training.

Is there a way to do this?

Thanks :)
- Marta

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by examining the BPR and WARP negative-sampling paths and how the interaction matrix is passed to training. Define how the excluded bottom-right block is represented and verify that sampled negatives never come from it; the issue provides no named files or tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.