Giter Site home page Giter Site logo

yitingss / triplet_loss_kws Goto Github PK

View Code? Open in Web Editor NEW

This project forked from roman-vygon/triplet_loss_kws

0.0 0.0 0.0 4.38 MB

Learning Efficient Representations for Keyword Spotting with Triplet Loss

License: MIT License

Python 97.31% Jupyter Notebook 2.69%

triplet_loss_kws's Introduction

Learning Efficient Representations for Keyword Spotting with Triplet Loss

Code for the paper Learning Efficient Representations for Keyword Spotting with Triplet Loss
by Roman Vygon([email protected]) and Nikolay Mikhaylovskiy([email protected]).

Prerequisites

Training

To train a triplet encoder run:

python TripletEncoder.py --name=test_encoder --manifest=MANIFEST --model=MODEL 

To train a no-triplet model, or to train a classifier based on the triplet encoder run:

python TripletClassifier.py --name=test_classifier --manifest=MANIFEST --model=MODEL

You can use --help to view the description of arguments.

Hardware Requirements

Training was performed on a single Tesla K80 12GB.

Model Batch Size VRAM
Res15 35*4 11GB
Res8 35*10 4GB

Testing

To test a triplet encoder run:

python infer_train.py --name=test_encoder --manifest=MANIFEST --model=MODEL --enc_step=ENCODER_TRAINING_STEP

To test a classifier-head model run:

python infer_notl.py --name=test_encoder --cl_name=test_classifier --manifest=MANIFEST --model=MODEL --enc_step=ENCODER_TRAINING_STEP --cl_step=CLASSIFIER_TRAINING_STEP

You can use --help to view the description of arguments.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

Datasets

LibriSpeech

You can download the test-clean-360 here: http://www.openslr.org/12. If the site doesn't load see this code for direct links to the files.

Google Speech Commands

Use this notebook to download and prepare the Google Speech Commands dataset.

Additional files

Data manifests, librispeech alignments and distance measures can be found here. You'll need to update the manifests.json file with the dataset path. You can convert LibriWords manifests with convert_path_prefix.ipynb

The files sadly went missing, I'll try to recover them, if anyone had a chance to download them please contact me.

triplet_loss_kws's People

Contributors

roman-vygon 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.