diff --git a/.gitignore b/.gitignore index beb1c04..62bfceb 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,6 @@ .ipynb_checkpoints __pycache__ -.env/* \ No newline at end of file +.env/* + +torchvggish.egg-info/ diff --git a/README.md b/README.md index 159f625..c1c716a 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,13 @@ except: urllib.request.urlretrieve(url, filename) model.forward(filename) ``` +If you want to modify hyperparameters in `torchvggish.vggish_params`, +add the following `install_requires` to your `setup.py`: +``` +"torchvggish @ git+https://github.com/neuralaudio/torchvggish.git@setup.py#egg=torchvggish", +``` +and then `import torchvggish.vggish_params` in your code. +
[1] S. Hershey et al., ‘CNN Architectures for Large-Scale Audio Classification’,\ in International Conference on Acoustics, Speech and Signal Processing (ICASSP),2017\ diff --git a/setup.py b/setup.py new file mode 100644 index 0000000..af04a6e --- /dev/null +++ b/setup.py @@ -0,0 +1,22 @@ +#!/usr/bin/env python3 +from setuptools import find_packages, setup + +long_description = open("README.md", "r", encoding="utf-8").read() + +setup( + name="torchvggish", + version="v0.1.1", + description="Pytorch port of Google Research's VGGish model used for extracting audio features.", + author="Harri Taylor", + author_email="harritaylor@protonmail.com", + url="https://github.com/harritaylor/torchvggish", + license="Apache-2.0", + long_description=long_description, + long_description_content_type="text/markdown", + packages=find_packages(), + python_requires=">=3.6", + install_requires=['torch', 'numpy', 'resampy', 'soundfile'], + extras_require={ + }, +) + diff --git a/torchvggish/__init__.py b/torchvggish/__init__.py new file mode 100644 index 0000000..e69de29