Git Product home page Git Product logo

pytorch-vqa-dan's Introduction

Dual Attention Networks for Visual Question Answering

This is a PyTorch implementation of Dual Attention Networks for Multimodal Reasoning and Matching. I forked the code from Cyanogenoid's pytorch-vqa and replaced the model with my implementation of Dual Attention Networks because doing all the data preprocessing and loading stuff is kinda nasty. Please see pytorch-vqa on how the data was preprocessed and extracted.

Differences between paper and this model

  • Learning rate decay: the original paper halved the learning after 30 epochs and trained for another 30 epochs. we used the forked code optimization and halved learning rate after 50k iterations.
  • Answer scoring: the original paper used only a single layer to score the answers with the memory vector. Our implementation uses a 2 layer network.
  • Pretrained word embeddings: the original paper used 512 as word embedding dimension. For the below graph, we used 300 and load pretrained Glove vectors.

Our implementation reaches around 61% validation accuracy after running 20 epochs. Learning graph

Requirements

Python version 3

  • h5py
  • torch
  • torchvision
  • tqdm
  • torchtext

Plotting

  • numpy
  • matplotlib

pytorch-vqa-dan's People

Contributors

tzuhsial avatar cyanogenoid avatar ankitshah009 avatar pplantinga avatar shijievvu 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.