Giter Club home page Giter Club logo

variational-siamese-network's Introduction

variational-siamese-network

Overview

Tensorflow implementation of Learning semantic similarity in a continuous space , Deudon M.

Requirements

Usage

To train/test a variational siamese network, you need some data.

The w2v folder holds pretrained models such as GloVe or Word2Vec. You can drag here any pretrained or custom model (We saved our weights and vocabulary in two files: embeddings_300d.p and vocab_300d.p).

In the data folder, you should put your data. We used quora_duplicate_questions.tsv. You should further put your train/dev/test files in the data/split folder (we saved those as .txt files). Your preprocessed data will be stored as .npy files in the folder named corpus.

  • To train a variational siamese network with generative pretraining (repeat), consider running the following in the folder _deepNLU:
> python train.py VAE
  • For the repeat, reformulate framework, consider running:
> python train.py VAD

The model will be saved in _deepNLU/save/.
Our neural architecture is specified in nnet.py and utility functions in utils.py.
Our data loader and preprocessing is specified in data.py.

  • To visualize generative and discriminative training on tensorboard, run:
> tensorboard --logdir=summary
  • To test a trained model, you can run eval.ipynb with the Jupyter Notebook.

Architecture and Training

Variational Auto Encoder (VAE)

Variational Siamese Network

Evaluation

Acknowledgments

Special thanks:

Author

Michel Deudon / @mdeudon

variational-siamese-network's People

Contributors

micheldeudon avatar

Watchers

James Cloos avatar normanj 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.