Git Product home page Git Product logo

pygru4rec's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pygru4rec's Issues

detach

hidden = reset_hidden(hidden, mask).detach()

  1. The code in the model.py, makes that loss of time t can only propogate to time t-1, which make the model more like a Markov Chain Model rather than a RNN modle?
  2. Supposing a session of m timesteps and an usual RNN model, loss of time t can propogate to all timesteps <=t-1;
  3. On this point, The pyGRU4REC is different from the theano version of GRU4REC?

Test result: recall:0.177/mrr:0.074 ?

Training GRU4REC...
epoch: 1/loss:5.118/recall:0.502/mrr:0.221/time:22.532
epoch: 2/loss:4.908/recall:0.599/mrr:0.267/time:22.467
epoch: 3/loss:4.867/recall:0.613/mrr:0.274/time:22.493
epoch: 4/loss:4.848/recall:0.619/mrr:0.276/time:22.521
epoch: 5/loss:4.836/recall:0.622/mrr:0.277/time:22.520
Test result: loss:5.878/recall:0.177/mrr:0.074/time:0.029

BUG?

mask = [] # indicator for the sessions to be terminated  
        finished = False          
        while not finished:  
            minlen = (end - start).min()

Here, mask = [] should be within the while loop while not finished: ?

The shape of logit in loss function

Dear Younghun Song,
First of all, I really thank you for your useful implementation. It is simpler than original code except a point. In function BPRLoss, I don't understand why the shape of logit is BxB. I think that it should be B x n_item.
Can you explain it to me?
Thank you for your help :)

Question about TOP1 Loss

Hi, thank you for your work.

Here I have a question for your top-1 loss implementation.

At modules/loss.py: line 56
loss = F.sigmoid(diff).mean() + F.sigmoid(logit ** 2).mean()

If I understood top-1 loss and your code, logit have already contained positive sample, but F.sigmoid(logit ** 2).mean() should be applied for only negative samples

Could you please check whether I understand right?

Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.