Skip to content

Commit

Permalink
renamed filter (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
nico-franco-gomez authored Mar 6, 2024
1 parent f46e91b commit 4fd065b
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 11 deletions.
6 changes: 3 additions & 3 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ adheres to `Semantic Versioning <http://semver.org/spec/v2.0.0.html>`_.
- Validation for results from tests in every module (so far many tests are
only regarding functionality)

`0.3.2 <https://pypi.org/project/dsptoolbox/0.3.2>`_ -
`0.3.3 <https://pypi.org/project/dsptoolbox/0.3.3>`_ -
---------------------

Added
~~~~~~~
- added variable state filter `VSFilter` discretized with a topology-preserving
transform
- added state variable filter `StateVariableFilter` discretized with a
topology-preserving transform

Misc
~~~~~~
Expand Down
2 changes: 1 addition & 1 deletion dsptoolbox/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,4 +73,4 @@
"effects",
]

__version__ = "0.3.2"
__version__ = "0.3.3"
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""
Variable-State filter topology-Preserving (trapezoidal integrators) 2-Pole multimode filter
State variable filter topology-Preserving (trapezoidal integrators)
2-Pole multimode filter
"""

import numpy as np
Expand All @@ -10,14 +11,14 @@
from ..generators import dirac


class VariableStateFilter:
"""This is a variable state filter discretized using the
class StateVariableFilter:
"""This is a state variable filter discretized using the
topology-preserving transform (trapezoidal integrator)."""

def __init__(
self, frequency_hz: float, resonance: float, sampling_rate_hz: int
):
"""Construct a variable state, 2-pole multimode filter. The
"""Construct a state variable, 2-pole multimode filter. The
implementation is based on [1], but the resonance parameter is here
equal to 2R.
Expand Down
4 changes: 2 additions & 2 deletions dsptoolbox/filterbanks/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@

from ..classes._lattice_ladder_filter import LatticeLadderFilter
from ..classes._phaseLinearizer import PhaseLinearizer
from ..classes._vsfilter import VariableStateFilter
from ..classes._svfilter import StateVariableFilter

__all__ = [
"linkwitz_riley_crossovers",
Expand All @@ -52,5 +52,5 @@
"complementary_fir_filter",
"LatticeLadderFilter",
"PhaseLinearizer",
"VariableStateFilter",
"StateVariableFilter",
]
2 changes: 1 addition & 1 deletion tests/test_filterbanks.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ def test_phase_linearizer(self):

def test_VSFilter(self):
fs_hz = 10_000
f = dsp.filterbanks.VariableStateFilter(500, np.sqrt(2), fs_hz)
f = dsp.filterbanks.StateVariableFilter(500, np.sqrt(2), fs_hz)

n = dsp.generators.noise(sampling_rate_hz=fs_hz)
f.filter_signal(n)
Expand Down

0 comments on commit 4fd065b

Please sign in to comment.