All Projects → benedekrozemberczki → NMFADMM

benedekrozemberczki / NMFADMM

Licence: GPL-3.0 License
A sparsity aware implementation of "Alternating Direction Method of Multipliers for Non-Negative Matrix Factorization with the Beta-Divergence" (ICASSP 2014).

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to NMFADMM

RolX
An alternative implementation of Recursive Feature and Role Extraction (KDD11 & KDD12)
Stars: ✭ 52 (+33.33%)
Mutual labels:  word2vec, deepwalk, matrix-factorization, factorization, unsupervised-learning, embedding, node2vec
M-NMF
An implementation of "Community Preserving Network Embedding" (AAAI 2017)
Stars: ✭ 119 (+205.13%)
Mutual labels:  deepwalk, matrix-factorization, factorization, unsupervised-learning, nmf, node2vec
Awesome Community Detection
A curated list of community detection research papers with implementations.
Stars: ✭ 1,874 (+4705.13%)
Mutual labels:  deepwalk, matrix-factorization, factorization, unsupervised-learning, embedding, node2vec
FSCNMF
An implementation of "Fusing Structure and Content via Non-negative Matrix Factorization for Embedding Information Networks".
Stars: ✭ 16 (-58.97%)
Mutual labels:  word2vec, deepwalk, pca, embedding, nmf, node2vec
walklets
A lightweight implementation of Walklets from "Don't Walk Skip! Online Learning of Multi-scale Network Embeddings" (ASONAM 2017).
Stars: ✭ 94 (+141.03%)
Mutual labels:  word2vec, deepwalk, embedding, node2vec, word-embedding
Quick-Data-Science-Experiments-2017
Quick-Data-Science-Experiments
Stars: ✭ 19 (-51.28%)
Mutual labels:  matrix-factorization, pca, lda, nmf
kwx
BERT, LDA, and TFIDF based keyword extraction in Python
Stars: ✭ 33 (-15.38%)
Mutual labels:  topic-modeling, lda, unsupervised-learning
Text-Analysis
Explaining textual analysis tools in Python. Including Preprocessing, Skip Gram (word2vec), and Topic Modelling.
Stars: ✭ 48 (+23.08%)
Mutual labels:  word2vec, lda, word-embedding
amazon-reviews
Sentiment Analysis & Topic Modeling with Amazon Reviews
Stars: ✭ 26 (-33.33%)
Mutual labels:  topic-modeling, lda, nmf
Graph2vec
A parallel implementation of "graph2vec: Learning Distributed Representations of Graphs" (MLGWorkshop 2017).
Stars: ✭ 605 (+1451.28%)
Mutual labels:  word2vec, matrix-factorization, unsupervised-learning
Tadw
An implementation of "Network Representation Learning with Rich Text Information" (IJCAI '15).
Stars: ✭ 43 (+10.26%)
Mutual labels:  word2vec, matrix-factorization, unsupervised-learning
deepvis
machine learning algorithms in Swift
Stars: ✭ 54 (+38.46%)
Mutual labels:  pca, lda, unsupervised-learning
RcppML
Rcpp Machine Learning: Fast robust NMF, divisive clustering, and more
Stars: ✭ 52 (+33.33%)
Mutual labels:  matrix-factorization, sparse-matrix, nmf
Gemsec
The TensorFlow reference implementation of 'GEMSEC: Graph Embedding with Self Clustering' (ASONAM 2019).
Stars: ✭ 210 (+438.46%)
Mutual labels:  word2vec, matrix-factorization, unsupervised-learning
lda2vec
Mixing Dirichlet Topic Models and Word Embeddings to Make lda2vec from this paper https://arxiv.org/abs/1605.02019
Stars: ✭ 27 (-30.77%)
Mutual labels:  word2vec, topic-modeling, lda
resolutions-2019
A list of data mining and machine learning papers that I implemented in 2019.
Stars: ✭ 19 (-51.28%)
Mutual labels:  deepwalk, node2vec
text-classification-cn
中文文本分类实践,基于搜狗新闻语料库,采用传统机器学习方法以及预训练模型等方法
Stars: ✭ 81 (+107.69%)
Mutual labels:  word2vec, embedding
PyLDA
A Latent Dirichlet Allocation implementation in Python.
Stars: ✭ 51 (+30.77%)
Mutual labels:  topic-modeling, lda
pyMCR
pyMCR: Multivariate Curve Resolution for Python
Stars: ✭ 55 (+41.03%)
Mutual labels:  unsupervised-learning, unsupervised-machine-learning
zAnalysis
zAnalysis是基于Pascal语言编写的大型统计学开源库
Stars: ✭ 52 (+33.33%)
Mutual labels:  pca, lda

Non-negative Matrix Factorization with Alternating Direction Method of Multipliers

License codebeat badge repo sizebenedekrozemberczki

A sparsity aware implementation of Alternating Direction Method of Multipliers for Non-Negative Matrix Factorization with the Beta-Divergence (ICASSP 2014).

Non-negative matrix factorization (NMF) is a popular method for learning interpretable features from non-negative data, such as counts or magnitudes. Different cost functions are used with NMF in different applications. We develop an algorithm, based on the alternating direction method of multipliers, that tackles NMF problems whose cost function is a beta-divergence, a broad class of divergence functions. We derive simple, closed-form updates for the most commonly used beta-divergences. We demonstrate experimentally that this algorithm has faster convergence and yields superior results to state-of-the-art algorithms for this problem.

The model is now also available in the package Karate Club.

This repository provides a sparsity aware implementation for ADMM based NMF as described in the paper:

Alternating Direction Method of Multipliers for Non-Negative Matrix Factorization with the Beta-Divergence. Dennis L. Sun and Cédric Févotte ICASSP 2014 [Paper]

An alternative implementation is available [here].

Requirements

The codebase is implemented in Python 3.5.2. package versions used for development are just below.

tqdm               4.28.1
numpy              1.15.4
pandas             0.23.4
texttable          1.5.0
scipy              1.1.0
argparse           1.1.0

Datasets

The code takes an input matrix from a csv file. Every row indicates a (user, item, value) triplet. Values are separated by commas and the first row is a header. Rows and columns should be indexed starting with 0. A sample matrix for the `Twitch Taiwan` dataset is included in the `input/` directory. The structure of the matrix is the following:

User ID Item ID Positive Value
0 3 10
1 1 1
2 2 12
3 1 17
... ... ...
n m 8

Options

The learning of the embedding is handled by the src/main.py script which provides the following command line arguments.

Input and output options

  --input-path      STR    Input matrix path.       Default is `input/twitch_taiwan.csv`.
  --user-path       STR    Item users path.         Default is `output/twitch_taiwan_user.csv`.
  --item-path       STR    item factors path.       Default is `output/twitch_taiwan_item.csv`.

Model options

  --epochs        INT     Number of training epochs.      Default is 100. 
  --dimensions    INT     Factor dimensions.              Default is 32.
  --rho           FLOAT   Regularization parameter.       Default is 1.0.

Examples

The following commands execute a factorization and save the row and column factors to disk as csv files.

Training an ADMM NMF model on the default dataset. Saving the factors at default paths.

python src/main.py

Creating a model with 128 features.

python src/main.py --dimensions 128

Creating a model with some custom regularization and epoch number.

python src/main.py --rho 10.0 --epochs 100

License


Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].