forked from JoFrhwld/FAVE
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/dev'
- Loading branch information
Showing
8 changed files
with
190 additions
and
39 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: Bug Report | ||
description: The software does something unwanted or unusual | ||
title: "[BUG]: " | ||
labels: ["bug"] | ||
|
||
body: | ||
- type: markdown | ||
attributes: | ||
value: | | ||
Thanks for taking the time to fill out this bug report! | ||
- type: checkboxes | ||
id: new-bug | ||
attributes: | ||
label: Did you search for similar bugs? | ||
description: Please search to see if an issue already exists for the bug you encountered. | ||
options: | ||
- label: I have searched the existing issues | ||
required: false | ||
- type: textarea | ||
id: bug-description | ||
attributes: | ||
label: What happened? | ||
description: Tell us what bug you encountered | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: bug-behaviour | ||
attributes: | ||
label: Expectations? | ||
description: Tell us what should have happened | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: steps-to-reproduce | ||
attributes: | ||
label: Steps To Reproduce | ||
description: Can you describe your steps, when you encountered the bug? | ||
placeholder: Please write the steps in a list form | ||
validations: | ||
required: false |
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 |
---|---|---|
|
@@ -7,6 +7,7 @@ | |
*.wav | ||
build/* | ||
docs/_build | ||
*.code-workspace | ||
*.swp | ||
*.orig | ||
env | ||
|
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,57 @@ | ||
|
||
import logging | ||
import pytest | ||
import numpy as np | ||
from fave import extractFormants | ||
|
||
def test_mean_stdv(): | ||
for test_case in provide_valuelist(): | ||
mean, stdv = extractFormants.mean_stdv(test_case[0]) | ||
|
||
assert mean == test_case[1] | ||
assert stdv == test_case[2] | ||
|
||
def provide_valuelist(): | ||
return [ | ||
[ | ||
[1, 2, 3, 4], | ||
np.mean([1, 2, 3, 4]), | ||
np.std([1, 2, 3, 4], ddof=1) | ||
], | ||
[ | ||
[3.5, 2.6, 11.6, 34.66, 2.8, 4.7], | ||
np.mean([3.5, 2.6, 11.6, 34.66, 2.8, 4.7]), | ||
np.std([3.5, 2.6, 11.6, 34.66, 2.8, 4.7], ddof=1) | ||
], | ||
[ | ||
[], | ||
None, | ||
None | ||
], | ||
[ | ||
[23, 34, 45, 56, 12, 312, 45, 943, 21, 1, 4, 6, 9, 2], | ||
np.mean([23, 34, 45, 56, 12, 312, 45, 943, 21, 1, 4, 6, 9, 2]), | ||
np.std([23, 34, 45, 56, 12, 312, 45, 943, 21, 1, 4, 6, 9, 2], ddof=1) | ||
], | ||
[ | ||
[3], | ||
np.mean([3]), | ||
0 | ||
], | ||
[ | ||
[-1], | ||
np.mean([-1]), | ||
0 | ||
] | ||
[ | ||
[3.5, 2.6, 11.6, None, 34.66, 2.8, 4.7], | ||
np.nanmean(np.array([3.5, 2.6, 11.6, None, 34.66, 2.8, 4.7], | ||
dtype=np.float64)), | ||
np.nanstd(np.array([3.5, 2.6, 11.6, None, 34.66, 2.8, 4.7], | ||
dtype=np.float64), | ||
ddof=1) | ||
] | ||
] | ||
|
||
|
||
|