Skip to content
Snippets Groups Projects
Commit 6823dc37 authored by valentin.emiya's avatar valentin.emiya
Browse files

update CI

parent 566518e4
Branches
Tags
No related merge requests found
Pipeline #5097 failed
...@@ -9,7 +9,7 @@ tests: ...@@ -9,7 +9,7 @@ tests:
- pip3 install --no-deps . - pip3 install --no-deps .
- python3 -c "from tffpy.utils import generate_config; generate_config()" - python3 -c "from tffpy.utils import generate_config; generate_config()"
- pwd - pwd
- python3 -c "from configparser import ConfigParser; from pathlib import Path; config.read('/root/.config/tffpy.conf'); config.set('DATA', 'data_path', str(Path(__file__.parent / 'data')); config - python3 -c "from configparser import ConfigParser; from pathlib import Path; config.read('/root/.config/tffpy.conf'); config.set('DATA', 'data_path', '/builds/skmad-suite/tff2020/data'); config.write(open('/root/.config/tffpy.conf', 'w'))"
- pytest-3 - pytest-3
# generate the documentation # generate the documentation
...@@ -25,9 +25,7 @@ pages: ...@@ -25,9 +25,7 @@ pages:
- pip3 install --no-deps . - pip3 install --no-deps .
- python3 setup.py build_sphinx - python3 setup.py build_sphinx
- python3 -c "from tffpy.utils import generate_config; generate_config()" - python3 -c "from tffpy.utils import generate_config; generate_config()"
- pwd - python3 -c "from configparser import ConfigParser; from pathlib import Path; config.read('/root/.config/tffpy.conf'); config.set('DATA', 'data_path', '/builds/skmad-suite/tff2020/data'); config.write(open('/root/.config/tffpy.conf', 'w'))"
- python3 -c "from configparser import ConfigParser; from pathlib import Path; config.read('/root/.config/tffpy.conf'); config.set('DATA', 'data_path', str(Path(__file__.parent / 'data')); config
- .write(open('/root/.config/tffpy.conf', 'w'))"
- cp -r build/sphinx/html public - cp -r build/sphinx/html public
artifacts: artifacts:
paths: paths:
......
...@@ -15,6 +15,28 @@ from tffpy.utils import plot_mask, plot_win ...@@ -15,6 +15,28 @@ from tffpy.utils import plot_mask, plot_win
def get_dgt_params(win_type, approx_win_len, hop, n_bins, def get_dgt_params(win_type, approx_win_len, hop, n_bins,
phase_conv='freqinv', sig_len=None): phase_conv='freqinv', sig_len=None):
"""
Build dictionary of DGT parameter
Parameters
----------
win_type : str
Window name, e.g. 'hann', 'gauss'
approx_win_len : int
Approximate window length for FIR windows and
hop : int
Hop size
n_bins : int
Number of frequency bins
phase_conv :
Phase convention
sig_len : int
Signal length
Returns
-------
"""
supported_wins = arg_firwin() | {'gauss'} supported_wins = arg_firwin() | {'gauss'}
msg = '{} not supported, try {}'.format(win_type, supported_wins) msg = '{} not supported, try {}'.format(win_type, supported_wins)
assert win_type in supported_wins, msg assert win_type in supported_wins, msg
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment