Package: openl3
OpenL3OpenL3 is an open-source Python library for computing deep audio and image embeddings.Please refer to thedocumentationfor detailed instructions and examples.UPDATE:Openl3 now has Tensorflow 2 support!NOTE:Whoops! A bug was reported in thetraining code, with the effect that positive audio-image pairs that come from the same video do not necessarily overlap in time. Nonetheless, the embedding still seems to capture useful semantic information.The audio and image embedding models provided here are published as part of [1], and are based on the Look, Listen and Learn approach [2]. For details about the embedding models and how they were trained, please see:Look, Listen and Learn More: Design Choices for Deep Audio EmbeddingsAurora Cramer, Ho-Hsiang Wu, Justin Salamon, and Juan Pablo Bello.IEEE Int. Conf. on Acoustics, Speech and Signal Processing (ICASSP), pages 3852–3856, Brighton, UK, May 2019.Installing OpenL3DependencieslibsndfileOpenL3 depends on thepysoundfilemodule to load audio files, which depends on the non-Python librarylibsndfile. On Windows and macOS, these will be installed viapipand you can therefore skip this step.
However, on Linux this must be installed manually via your platform's package manager.
For Debian-based distributions (such as Ubuntu), this can be done by simply runningapt-get install libsndfile1Alternatively, if you are usingconda, you can installlibsndfilesimply by runningconda install -c conda-forge libsndfileFor more detailed information, please consult thepysoundfileinstallation documentation.TensorflowStarting withopenl3>=0.4.0, Openl3 has been upgraded to use Tensorflow 2. Because Tensorflow 2 and higher now includes GPU support,tensorflow>=2.0.0is included as a dependency and no longer needs to be installed separately.If you are interested in using Tensorflow 1.x, please install usingpip install 'openl3<=0.3.1'.Tensorflow 1x & OpenL3 <= v0.3.1Because Tensorflow 1.x comes in CPU-only and GPU variants, we leave it up to the user to install the version that best fits
their usecase.On most platforms, either of the following commands should properly install Tensorflow:pipinstall"tensorflow<1.14"# CPU-only versionpipinstall"tensorflow-gpu<1.14"# GPU versionFor more detailed information, please consult theTensorflow installation documentation.Installing OpenL3The simplest way to install OpenL3 is by usingpip, which will also install the additional required dependencies
if needed. To install OpenL3 usingpip, simply runpip install openl3To install the latest version of OpenL3 from source:Clone or pull the latest version, only retrieving themainbranch to avoid downloading the branch where we store the model weight files (these will be properly downloaded during installation).git clone git@github.com:marl/openl3.git --branch main --single-branchInstall using pip to handle python dependencies. The installation also downloads model files,which requires a stable network connection.cd openl3
 pip install -e .Using OpenL3To help you get started with OpenL3 please see thetutorial.Acknowledging OpenL3Please cite the following papers when using OpenL3 in your work:[1]Look, Listen and Learn More: Design Choices for Deep Audio EmbeddingsAurora Cramer, Ho-Hsiang Wu, Justin Salamon, and Juan Pablo Bello.IEEE Int. Conf. on Acoustics, Speech and Signal Processing (ICASSP), pages 3852–3856, Brighton, UK, May 2019.[2]Look, Listen and LearnRelja Arandjelović and Andrew ZissermanIEEE International Conference on Computer Vision (ICCV), Venice, Italy, Oct. 2017.Model Weights LicenseThe model weights are made available under aCreative Commons Attribution 4.0 International (CC BY 4.0) License.