Coder Social home page Coder Social logo

neural-machine-translation's Introduction

Neural Machine Translation

This program is able to automatically translate sentences from French to English using a neural network trained on 10,000 pairs of sentences written in both languages. The architecture used is an encoder-decoder LSTM (Long Short-Term Memory) network.

Requirements

You can install the required packages using pip install -r requirements.txt. For tensorflow packages, it is better to run conda install -c conda-forge tensorflow on an Anaconda prompt (with administrator rights). Once tensorflow is installed, run conda install -c conda-forge keras then conda install -c anaconda pydot and finally conda install -c anaconda graphviz. If you do not have Anaconda distribution on your computer, check out this page.

Data

The dataset used is available on the Data folder. It is taken from the ManyThings.org website. The dataset contains more than 150,000 pairs of French & English sentences. However, for the sake of time in the trial-and-error phase of the program's development, only 10,000 of those were used.

Usage

Run the python file main.py. This will:

  • give an insight into the data after the cleaning by printing the first few lines,
  • then train the model on the cleaned data (it may take up to 10min).
  • Finally, it will print the BLEU score for the model on both training and test set as well as an insight into the translations made by printing a sample of the predictions.

neural-machine-translation's People

Contributors

luca-serra avatar

Stargazers

 avatar

Watchers

 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.