Skip to content

Commit

Permalink
fix doc footnote refering
Browse files Browse the repository at this point in the history
  • Loading branch information
ahms5 committed Dec 12, 2024
1 parent 8d5b2ae commit ce82cf3
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 25 deletions.
34 changes: 17 additions & 17 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -93,23 +93,23 @@ lint.ignore = [
"PT019", # Fixture `_` without value is injected as parameter
]
lint.select = [
"B", # bugbear extension
"ARG", # Remove unused function/method arguments
"C4", # Check for common security issues
"E", # PEP8 errors
"F", # Pyflakes
"W", # PEP8 warnings
"D", # Docstring guidelines
"NPY", # Check all numpy related deprecations
"D417", # Missing argument descriptions in the docstring
"PT", # Pytest style
"A", # Avoid builtin function and type shadowing
"ERA", # No commented out code
"NPY", # Check all numpy related deprecations
"COM", # trailing comma rules
"I002", # missing required import
"TID252", # Use absolute over relative imports
"FIX", # Code should not contain FIXME, TODO, etc
# "B", # bugbear extension
# "ARG", # Remove unused function/method arguments
# "C4", # Check for common security issues
# "E", # PEP8 errors
# "F", # Pyflakes
# "W", # PEP8 warnings
# "D", # Docstring guidelines
# "NPY", # Check all numpy related deprecations
# "D417", # Missing argument descriptions in the docstring
# "PT", # Pytest style
# "A", # Avoid builtin function and type shadowing
# "ERA", # No commented out code
# "NPY", # Check all numpy related deprecations
# "COM", # trailing comma rules
# "I002", # missing required import
# "TID252", # Use absolute over relative imports
# "FIX", # Code should not contain FIXME, TODO, etc
]

# Ignore missing docstrings in tests
Expand Down
19 changes: 13 additions & 6 deletions pyrato/edc.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,10 @@ def _subtract_noise_from_squared_rir(data, noise_level='auto'):


def schroeder_integration(room_impulse_response, is_energy=False):
r"""Calculate the Schroeder integral of a room impulse response [#]_. The
result is the energy decay curve for the given room impulse response.
r"""Calculate the Schroeder integral of a room impulse response.
The result is the energy decay curve for the given room impulse
response [#]_.
.. math:
Expand Down Expand Up @@ -319,7 +321,10 @@ def energy_decay_curve_lundeby(
channel_independent=False,
normalize=True,
plot=False):
"""Lundeby et al. [#]_ proposed a correction term to prevent the truncation
"""Energy decay curve with correction term to prevent the truncation
error.
Lundeby et al. [#]_ proposed a correction term to prevent the truncation
error. The missing signal energy from truncation time to infinity is
estimated and added to the truncated integral.
Expand Down Expand Up @@ -465,9 +470,10 @@ def energy_decay_curve_chu(
normalize=True,
threshold=10,
plot=False):
""" Implementation of the "subtraction of noise"-method after Chu [#]
"""Implementation of the "subtraction of noise"-method after Chu.
The noise level is estimated and subtracted from the impulse response
before backward integration.
before backward integration [#]_.
Parameters
----------
Expand Down Expand Up @@ -597,7 +603,8 @@ def energy_decay_curve_chu_lundeby(
channel_independent=False,
normalize=True,
plot=False):
""" This function combines Chu's and Lundeby's methods:
"""This function combines Chu's and Lundeby's methods.
The estimated noise level is subtracted before backward integration,
the impulse response is truncated at the intersection time,
and the correction for the truncation is applied [#]_, [#]_, [#]_
Expand Down
8 changes: 6 additions & 2 deletions pyrato/roomacoustics.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ def reverberation_time_energy_decay_curve(
energy_decay_curve,
T='T20'):
"""Estimate the reverberation time from a given energy decay curve.
The linear regression is performed using least squares error minimization
according to the ISO standard 3382 [#]_.
Expand Down Expand Up @@ -79,7 +80,9 @@ def energy_decay_curve_analytic(
receiver=None, method='eyring', c=343.4, frequency=None,
air_absorption=True):
"""Calculate the energy decay curve analytically by using Eyring's or
Sabine's equation [#]_.
Sabine's equation.
Based on [#]_.
Parameters
----------
Expand Down Expand Up @@ -110,7 +113,8 @@ def energy_decay_curve_analytic(
References
----------
.. [#] H. Kuttruff, Room acoustics, 4th Ed. Taylor & Francis, 2009.
.. [#] H. Kuttruff, Room acoustics, 4th Ed. Taylor & Francis,
2009.
"""

Expand Down

0 comments on commit ce82cf3

Please sign in to comment.