-
Notifications
You must be signed in to change notification settings - Fork 946
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Data loader / more example tracks (#1150)
* implemented pooch loader, starts #952 * added librosa data cache to travis config * deprecated example audio file * added license + metadata display * updated examples * updated beat tracking doc examples * updated decompose examples * more docstring example updates * more docstring example updates * more docstring example updates * updated feature examples * updated examples except cqt * fixed clicks docstring example * added tests for data loader * fixed load-resample tests * fixed example-list test * cache the appveyor cache * updated cache documentation * fixing windows backslashing silliness * removed waller * removed waller * updated data path * added another example, revised advanced example gallery * updated pcen example to match sampling rate correctly * updated librosa data path * updated docs to describe example files * updated docstrings examples for cqt/vqt
- Loading branch information
Showing
48 changed files
with
625 additions
and
392 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file removed
BIN
-8.08 MB
docs/examples/audio/Cheese_N_Pot-C_-_16_-_The_Raps_Well_Clean_Album_Version.mp3
Binary file not shown.
Binary file not shown.
Binary file removed
BIN
-921 KB
docs/examples/audio/Kevin_MacLeod_-_Camille_Saint-Sans_Danse_Macabre_-_Sad_Part.mp3
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file removed
BIN
-5.61 MB
docs/examples/audio/We_Is_Shore_Dedicated_-_12_-_12_Sometimes_With_Friends.mp3
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -54,6 +54,7 @@ Advanced topics | |
cache | ||
ioformats | ||
advanced | ||
recordings | ||
|
||
Reference | ||
--------- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
Example files | ||
^^^^^^^^^^^^^ | ||
|
||
*librosa* includes a small selection of example recordings which are primarily used | ||
to demonstrate different functions of the library. | ||
Beginning with version 0.8, these examples are automatically retrieved from a remote | ||
server upon request. | ||
Example recordings are cached locally after the first request, so each file should | ||
only be downloaded once. | ||
|
||
|
||
Downloading files directly | ||
-------------------------- | ||
|
||
If you want to ensure that example data are always present on your computer, you can | ||
clone the data repository directly:: | ||
|
||
$ git clone https://github.com/librosa/data.git /path/to/librosa-data | ||
|
||
To ensure that *librosa* can find the example files, you can set the | ||
`LIBROSA_DATA_DIR` environment variable prior to importing *librosa*:: | ||
|
||
$ export LIBROSA_DATA_DIR=/path/to/librosa-data/audio | ||
$ python my_librosa_script.py | ||
|
||
or, directly in Python:: | ||
|
||
>>> import os | ||
>>> os.environ['LIBROSA_DATA_DIR'] = '/path/to/librosa-data/audio' | ||
>>> import librosa | ||
This will bypass any remote network access and use the local copies of the data | ||
files directly. | ||
|
||
|
||
Description of examples | ||
----------------------- | ||
|
||
The function `librosa.util.list_examples()` provides a brief description of each | ||
track, and `librosa.util.example_info()` will provide some metadata and licensing | ||
information for a given track. | ||
|
||
The following table describes in more detail what the recordings are, and how they | ||
are mainly used in the documentation. | ||
`Key` indicates the descriptor used to identify the track when calling `librosa.example()`. | ||
|
||
========== =========================================== ============================================================================ | ||
Key Full name Description | ||
========== =========================================== ============================================================================ | ||
brahms Brahms - Hungarian Dance #5 A short performance of this piece, with soft note onsets and variable tempo. | ||
choice Admiral Bob - Choice A short drum and bass loop, good for demonstrating decomposition methods. | ||
fishin Karissa Hobbs - Let's Go Fishin' A folk/pop song with verse/chorus/verse structure and vocals. | ||
nutcracker Tchaikovsky - Dance of the Sugar Plum Fairy Orchestral piece included to demonstrate tempo and harmony features. | ||
trumpet Mihai Sorohan - Trumpet loop Monophonic trumpet recording, good for demonstrating pitch features. | ||
vibeace Kevin Macleod - Vibe Ace A vibraphone, piano, and bass combo. Previously the only included example. | ||
========== =========================================== ============================================================================ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.