Skip to content

BandStopFilter is not useful for environmental sounds at high sample rates #159

@mariusfaiss

Description

@mariusfaiss

I am working with environmental recordings of insect sounds at 44.1 kHz that have little frequency content below 2.5 kHz and go up into the ultrasonic range. For my use-case, I would like to apply filters evenly over the entire spectrum without the center frequency affecting the filter bandwidth. If I set the upper and lower bandwidth limits to the same value, the resulting filters should be the same width, regardless of where their center frequencies are. BandStopFilter does not allow for this (as far as I can tell) and also produces errors in self._lowpasses when generating filters at higher center frequencies (ValueError: A cutoff above 0.5 does not make sense). It also seems like filters are more likely to be generated in lower frequency ranges than higher ones.

It would be nice if filter bandwidth could be decoupled from the center frequency, e.g. randomized between an upper and lower bandwidth in Hertz. And if center frequencies could be generated evenly over the entire spectrum. These could be implemented as options since it seems like the current functionality is more aimed towards use with human-centric sounds, perhaps on a mel-frequency scale. But having the option to evenly affect larger spectra would allow use with non-human and environmental sounds.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions