- Bump minimum matplotlib to 3.5.0 - Update to 0.10.2.post1: - Multiple accidentals by @erabinov in #1739 - Avoid deprecated matplotlib functions by @bmcfee in #1755 - Mode support by @erabinov in #1756 - Mode support by @erabinov in #1762 - Switch from pkg_resources to importlib.resources by @mattpitkin in #1765 - Add python 3.11 to build matrix by @bmcfee in #1769 - Natural accidentals for out-of-key notes by @erabinov in #1770 - Fix docstring for the writeable argument of util.frame function by @alvingao in #1780 - Update test_util.py to remove problematic "dummy". by @dpwe in #1783 - Updates matplotlib colormap usage to remove deprecation warnings. by @psmskelton in #1782 - Better handling of warnings in test suite by @bmcfee in #1784 - Fix sample rate type annotations by @bmcfee in #1789 - Explicitly allow scalars in decibel conversion by @bmcfee in #1790 - Adding python 3.12 to build matrix, update tests for recent scipy / numpy by @bmcfee in #1808 - Resolve the performance issue of autocorrelate by @alumkal in #1813 - Correct phase advance for odd frame lengths in phase_vocoder by @bmcfee in #1814 - Multichannel peak, onset, and beat detection by @bmcfee in #1766 - Update actions for 2024 by @bmcfee in #1820 - doc copybutton, CI updates by @bmcfee in #1821 - exposed tempo min and max parameters in specshow by @bmcfee in #1822 - remove kwargs from effects.hpss and friends, passthru stft by @bmcfee in #1826 - Docstring and comment improvements by @bmcfee in #1827 - librosa.cite() by @bmcfee in #1829 - 0.10.2 release prep by @bmcfee in #1832 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-librosa?expand=0&rev=48
48 lines
1.6 KiB
Python
48 lines
1.6 KiB
Python
""" librosa-create-pooch-cache.py
|
|
|
|
Create the pooch cache tarball for testing the package.
|
|
|
|
Copyright (c) 2021 SUSE LLC
|
|
Copyright (c) 2021 Ben Greiner <code@bnavigator.de>
|
|
|
|
All modifications and additions to the file contributed by third parties
|
|
remain the property of their copyright owners, unless otherwise agreed
|
|
upon. The license for this file, and modifications and additions to the
|
|
file, is the same license as for the pristine package itself (unless the
|
|
license for the pristine package is not an Open Source License, in which
|
|
case the license is the MIT License). An "Open Source License" is a
|
|
license that conforms to the Open Source Definition (Version 1.9)
|
|
published by the Open Source Initiative.
|
|
|
|
Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
"""
|
|
|
|
import os
|
|
import subprocess
|
|
import sys
|
|
|
|
import pooch
|
|
|
|
data_name = "librosa-pooch-cache"
|
|
registry_file = "librosa/util/example_data/registry.txt"
|
|
|
|
if len(sys.argv) != 2:
|
|
print(f"Usage: python3 {sys.argv[0]} <librosa-srcdir>")
|
|
print(f"Download test data into $PWD/{data_name} and compress the directory into $PWD/{data_name}.tar.gz")
|
|
sys.exit(1)
|
|
|
|
srcdir = os.path.abspath(sys.argv[1])
|
|
data_path = os.path.abspath(os.getcwd() + "/" + data_name)
|
|
|
|
|
|
pc = pooch.create(
|
|
data_path, base_url="https://librosa.org/data/audio/", registry=None
|
|
)
|
|
pc.load_registry(srcdir + "/" + registry_file)
|
|
with open(srcdir + "/" + registry_file) as fh:
|
|
for line in fh:
|
|
filename, hsum = line.split(" ")
|
|
pc.fetch(filename)
|
|
|
|
subprocess.run(["tar", "czf", f"{data_name}.tar.gz", data_name], check=True)
|