An open API service indexing awesome lists of open source software.

https://github.com/dfdx/lastfm-rbm

Example of using RBM for analysis of Last.fm data
https://github.com/dfdx/lastfm-rbm

Last synced: 6 months ago
JSON representation

Example of using RBM for analysis of Last.fm data

Awesome Lists containing this project

README

          

Applying Bernoulli RBM to Last.fm data
======================================

This is a short example of using Restricted Boltzmann Machines for learning internal structure of data.
Corresponding slides may be found [here](https://docs.google.com/presentation/d/1u1GE2jhvGPLaIXVid4KUPc8hBMCINzmzQZJz9BRfFGw/edit?usp=sharing)

How to repeat the experiment
----------------------------

1. Install Julia. I used stable v0.3, didn't test on other versions (did you? let me know).

2. Install libraries. In Julia prompt type:

Pkg.add("DataFrames")
Pkg.add("HDF5")
Pkg.clone("git@github.com:faithlessfriend/Boltzmann.jl.git")

3. Download dataset from [here](http://mtg.upf.edu/node/1671).

4. Update `DATA_DIR` in `data.jl` to reflect path to the dataset (one day I'll re-work this stuff... one day...).

5. Prepare data. From Julia prompt, load `prepare.jl` and then call:

prepare()

6. Fit model. From Julia prompt, load `fit.jl` and call:

fit_and_save()

7. Load model and analyse. From Julia prompt, load `analysis.jl` and type:

model, artists = load_fitted()
W = components(model)
# do analysis

I'm not a freak like you, can I use other tools?
------------------------------------------------

Julia is a wonderful programming language, but it's still on its way up. If you want to use something more stable and mature, Pandas and SciKit Learn (e.g. see [BernoulliRBM](https://github.com/scikit-learn/scikit-learn/blob/master/sklearn/neural_network/rbm.py)) should work as well. Also see [Pylearn2](https://github.com/lisa-lab/pylearn2/) for more deep learning oriented library.

**Found an error in this README? Report an issue!**