harm-analysis 1.2.1__tar.gz → 1.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/PKG-INFO +30 -5
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/README.md +27 -4
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/pyproject.toml +6 -2
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/src/harm_analysis/__init__.py +2 -2
- harm_analysis-1.2.1/src/harm_analysis/harm_analysis.py → harm_analysis-1.4.0/src/harm_analysis/_harm_analysis.py +374 -263
- harm_analysis-1.4.0/src/harm_analysis/cli.py +142 -0
- harm_analysis-1.2.1/tests/test_cli.py → harm_analysis-1.4.0/tests/conftest.py +6 -44
- harm_analysis-1.2.1/tests/test_harm_analysis_cli.py → harm_analysis-1.4.0/tests/test_cli.py +53 -27
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/tests/test_harm_analysis.py +18 -58
- harm_analysis-1.4.0/tests/test_spectrum_analysis.py +125 -0
- harm_analysis-1.2.1/src/harm_analysis/cli.py +0 -75
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/LICENSE +0 -0
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/tests/__init__.py +0 -0
- {harm_analysis-1.2.1 → harm_analysis-1.4.0}/tests/test_data_cli.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: harm-analysis
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.4.0
|
|
4
4
|
Summary: A Python library to estimate parameters from a signal containing a tone.
|
|
5
5
|
Keywords: DSP,Signal-Processing,THD,SNR
|
|
6
6
|
Author-Email: Eric Macedo <ericsmacedo@gmail.com>
|
|
@@ -14,23 +14,48 @@ Project-URL: Homepage, https://github.com/ericsmacedo/harm-analysis
|
|
|
14
14
|
Project-URL: Documentation, https://harm-analysis.readthedocs.io/en/stable/
|
|
15
15
|
Project-URL: Bug Tracker, https://github.com/ericsmacedo/harm-analysis/issues
|
|
16
16
|
Requires-Python: <4.0,>=3.10.0
|
|
17
|
+
Requires-Dist: bottleneck>=1.6.0
|
|
17
18
|
Requires-Dist: click>=8.2.1
|
|
18
19
|
Requires-Dist: matplotlib>=3.10.3
|
|
19
20
|
Requires-Dist: numpy>=2.2.6
|
|
21
|
+
Requires-Dist: rich>=14.1.0
|
|
20
22
|
Requires-Dist: scipy>=1.15.3
|
|
21
23
|
Description-Content-Type: text/markdown
|
|
22
24
|
|
|
23
25
|
|
|
24
26
|
[](https://badge.fury.io/py/harm-analysis)
|
|
25
27
|
[](https://github.com/ericsmacedo/harm-analysis/actions/workflows/main.yml)
|
|
26
|
-
[](https://harm-analysis.readthedocs.io/en/latest/)
|
|
27
29
|
[](https://coveralls.io/github/ericsmacedo/harm-analysis?branch=main)
|
|
28
30
|
[](https://pypi.python.org/pypi/harm-analysis)
|
|
29
31
|
[](https://semver.org/)
|
|
30
32
|
|
|
31
33
|
[](https://pypi.python.org/pypi/harm-analysis)
|
|
32
|
-
[](https://github.com/ericsmacedo/harm-analysis/graphs/contributors/)
|
|
33
34
|
[](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request)
|
|
34
35
|
[](https://github.com/ericsmacedo/harm-analysis/issues)
|
|
35
|
-
|
|
36
|
-
|
|
36
|
+
|
|
37
|
+
# Harmonic Analysis package
|
|
38
|
+
|
|
39
|
+
* [Documentation](https://harm-analysis.readthedocs.io/en/latest/)
|
|
40
|
+
* [PyPI](https://pypi.org/project/harm-analysis/)
|
|
41
|
+
* [Sources](https://github.com/ericsmacedo/harm-analysis)
|
|
42
|
+
* [Issues](https://github.com/ericsmacedo/harm-analysis/issues)
|
|
43
|
+
|
|
44
|
+
## Introduction
|
|
45
|
+
|
|
46
|
+
The harmonic analysis package uses FFT to estimate parameters of an input signal.
|
|
47
|
+
The package provides two main functions:
|
|
48
|
+
|
|
49
|
+
- `harm_analysis`: for simulations with an injected tone, returning SNR, THDN, Noise, etc.
|
|
50
|
+
- `spec_analysis`: for cases without an injected tone, that auto-detects DC, tones, and noise from the spectrum.
|
|
51
|
+
|
|
52
|
+
See [usage](./docs/usage.md) for examples.
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
## Installation
|
|
56
|
+
|
|
57
|
+
Installing it is pretty easy:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
pip install harm-analysis
|
|
61
|
+
```
|
|
@@ -1,14 +1,37 @@
|
|
|
1
1
|
|
|
2
2
|
[](https://badge.fury.io/py/harm-analysis)
|
|
3
3
|
[](https://github.com/ericsmacedo/harm-analysis/actions/workflows/main.yml)
|
|
4
|
-
[](https://harm-analysis.readthedocs.io/en/latest/)
|
|
5
5
|
[](https://coveralls.io/github/ericsmacedo/harm-analysis?branch=main)
|
|
6
6
|
[](https://pypi.python.org/pypi/harm-analysis)
|
|
7
7
|
[](https://semver.org/)
|
|
8
8
|
|
|
9
9
|
[](https://pypi.python.org/pypi/harm-analysis)
|
|
10
|
-
[](https://github.com/ericsmacedo/harm-analysis/graphs/contributors/)
|
|
11
10
|
[](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request)
|
|
12
11
|
[](https://github.com/ericsmacedo/harm-analysis/issues)
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
|
|
13
|
+
# Harmonic Analysis package
|
|
14
|
+
|
|
15
|
+
* [Documentation](https://harm-analysis.readthedocs.io/en/latest/)
|
|
16
|
+
* [PyPI](https://pypi.org/project/harm-analysis/)
|
|
17
|
+
* [Sources](https://github.com/ericsmacedo/harm-analysis)
|
|
18
|
+
* [Issues](https://github.com/ericsmacedo/harm-analysis/issues)
|
|
19
|
+
|
|
20
|
+
## Introduction
|
|
21
|
+
|
|
22
|
+
The harmonic analysis package uses FFT to estimate parameters of an input signal.
|
|
23
|
+
The package provides two main functions:
|
|
24
|
+
|
|
25
|
+
- `harm_analysis`: for simulations with an injected tone, returning SNR, THDN, Noise, etc.
|
|
26
|
+
- `spec_analysis`: for cases without an injected tone, that auto-detects DC, tones, and noise from the spectrum.
|
|
27
|
+
|
|
28
|
+
See [usage](./docs/usage.md) for examples.
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
## Installation
|
|
32
|
+
|
|
33
|
+
Installing it is pretty easy:
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
pip install harm-analysis
|
|
37
|
+
```
|
|
@@ -16,9 +16,11 @@ classifiers = [
|
|
|
16
16
|
]
|
|
17
17
|
requires-python = ">=3.10.0,<4.0"
|
|
18
18
|
dependencies = [
|
|
19
|
+
"bottleneck>=1.6.0",
|
|
19
20
|
"click>=8.2.1",
|
|
20
21
|
"matplotlib>=3.10.3",
|
|
21
22
|
"numpy>=2.2.6",
|
|
23
|
+
"rich>=14.1.0",
|
|
22
24
|
"scipy>=1.15.3",
|
|
23
25
|
]
|
|
24
26
|
keywords = [
|
|
@@ -27,7 +29,7 @@ keywords = [
|
|
|
27
29
|
"THD",
|
|
28
30
|
"SNR",
|
|
29
31
|
]
|
|
30
|
-
version = "1.
|
|
32
|
+
version = "1.4.0"
|
|
31
33
|
|
|
32
34
|
[project.urls]
|
|
33
35
|
Homepage = "https://github.com/ericsmacedo/harm-analysis"
|
|
@@ -35,12 +37,14 @@ Documentation = "https://harm-analysis.readthedocs.io/en/stable/"
|
|
|
35
37
|
"Bug Tracker" = "https://github.com/ericsmacedo/harm-analysis/issues"
|
|
36
38
|
|
|
37
39
|
[project.scripts]
|
|
38
|
-
harm-analysis = "harm_analysis.cli:
|
|
40
|
+
harm-analysis = "harm_analysis.cli:harm_analysis_cmd"
|
|
41
|
+
spec-analysis = "harm_analysis.cli:spec_analysis_cmd"
|
|
39
42
|
|
|
40
43
|
[dependency-groups]
|
|
41
44
|
dev = [
|
|
42
45
|
"contextlib-chdir>=1.0.2",
|
|
43
46
|
"coveralls>=3.3.1",
|
|
47
|
+
"invoke>=2.2.0",
|
|
44
48
|
"mkdocs-click>=0.8.1",
|
|
45
49
|
"mkdocs-include-markdown-plugin>=6.0.5",
|
|
46
50
|
"mkdocs-literate-nav>=0.6.1",
|