Skip to content

Latest commit

 

History

History
 
 

audio-search

Table of Contents

Build Audio Search with Vggish

Jina Jina Jina Jina Docs We are hiring tweet button Python 3.7 3.8 Docker

A demo of neural search for audio data based Vggish model.

Jina banner

Install Prerequisites

pip install -r requirements.txt

Download Model

bash download_model.sh
bash download_data.sh

After preparing the data, here is how the folder looks like,

.
├── Dockerfile
├── README.md
├── app.py
├── data
│   ├── YjmN-c5mDxfw.wav
│   ├── Yjo9lFbGXf_0.wav
│   └── Yjzij1UX73kU.wav
├── download.sh
├── flows
│   ├── index.yml
│   └── query.yml
├── models
│   ├── vggish_model.ckpt
│   └── vggish_pca_params.npz
├── pods
│   ├── craft.yml
│   ├── customized_executors.py
│   ├── doc.yml
│   ├── encode.yml
│   ├── rank.yml
│   ├── vec.yml
│   └── vggish
│       ├── mel_features.py
│       ├── vggish_input.py
│       ├── vggish_params.py
│       ├── vggish_postprocess.py
│       └── vggish_slim.py
└── requirements.txt
  • Alternatively, you can also use you own .wav files. Make sure the files are under data/. For example, our get_data.sh script downloads a few Beethoven symphonies from Wikimedia Commons. This is a small dataset so indexes quickly. Just run
sh ./get_data.sh

Run

Command Description
python app.py -t index To index files/data
python app.py -t query To run query on the index

Then open https://jina.ai/jinabox.js/ for querying.

Run as a Docker Container

To mount local directory and run:

docker run -v "$(pwd)/data:/workspace/data" -v "$(pwd)/workspace:/workspace/workspace" jinaai/hub.app.audio-search:0.0.1 index

Run the following cmd and open https://jina.ai/jinabox.js/ for querying

docker run -p 65481:65481 -e "JINA_PORT=65481" -v "$(pwd)/workspace:/workspace/workspace" jinaai/hub.app.audio-search:0.0.1 search

Documentation

The best way to learn Jina in-depth is to read our documentation. Documentation is built on every push, merge, and release event of the master branch. For more details, check out:

Community

  • Slack channel - a communication platform for developers to discuss Jina
  • Community newsletter - subscribe to the latest update, release and event news of Jina
  • LinkedIn - get to know Jina AI as a company and find job opportunities
  • Twitter Follow - follow us and interact with us using hashtag #JinaSearch
  • Company - know more about our company, we are fully committed to open-source!

License

Copyright (c) 2020 Jina AI. All rights reserved.