Git Product home page Git Product logo

wtopic's Introduction

wtopic

weighted topic modeling. Experiments in augmenting topic-modeling methods, if given an a priori measurement of the distances between words

Benchmark

Given the newsgroup dataset, construct a low-dimensional topic embedding. For each newsgroup, construct a mean vector from all documents in it. Evaluation is the percent of documents that are closest (in embedding space) to their correct label.

Results

This seems to help both LDA and LSA methods, except for low-dimension LDA embeddings. Notably, the best results on this benchmark came from LSA with tf-idf weights, with the improved method.

Method k weight distance Improvement
LSA 5 vec cosine 3.68%
LSA 10 vec cosine 5.17%
LSA 20 vec cosine 10.43%
LSA 30 vec cosine 61.40%
LDA 5 vec euclid -16.73%
LDA 10 vec euclid -5.75%
LDA 20 vec euclid 5.40%
LDA 30 vec euclid 19.55%
LSA 10 idf euclid 6.10%
LSA 20 idf cosine 6.78%
LSA 30 idf cosine 5.35%

Issues

The method forces parts of these "sparse" algorithms to be dense. This can be augmented by only storing the closest-N pairwise distances for each word. However, this would still make the procedure more dense.

Other stuff

There is also a small subset of the newsgroup dataset in here. Along with a script to fetch GLoVe vectors to generating embedding distances. There is also a version of Funk's SVD that I implemented to do approximate LSA, but this didn't really work well

wtopic's People

Contributors

leonidk avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar

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.