GithubHelp home page GithubHelp logo

jfpuget / libfm_in_keras Goto Github PK

View Code? Open in Web Editor NEW
188.0 188.0 50.0 56 KB

This notebook shows how to implement LibFM in Keras and how it was used in the Talking Data competition on Kaggle.

License: Apache License 2.0

Jupyter Notebook 100.00%

libfm_in_keras's People

Contributors

jfpuget avatar

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

libfm_in_keras's Issues

how about the continuous variable?

hi,
as we can see from the codes:
i):features = ['os', 'device', 'app']
f_size = [int(data[f].max()) + 1 for f in features]

ii) def get_embed(x_input, x_size, k_latent):
if x_size > 0: #category
embed = Embedding(x_size, k_latent, input_length=1,
embeddings_regularizer=l2(embedding_reg))(x_input)
embed = Flatten()(embed)
else:
embed = Dense(k_latent, kernel_regularizer=l2(embedding_reg))(x_input)
return embed

iii) biases = [get_embed(x, size, 1) for (x, size) in zip(input_x, f_size)]
factors = [get_embed(x, size, k_latent) for (x, size) in zip(input_x, f_size)]

in the demo,there are all the category variable in the data,
can you show us how to handle with continuous variable?or make continuous variable into bins?
looking for your reply!
^_^

input data format

Hi,
Many thanks sharing this code.
Having the output file, how is it possible to connect it to the original dataset ? I'm using panda, is there any special command doing it ? Appear to me that the usual "merge on" command is not working with multiple columns

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.