Skip to content

It seems that the "true" low frequencies will be lost if a target bin receives contributions from multiple source bins #1

@stephanemagnenat

Description

@stephanemagnenat

In line 166 the frequency is overwritten, while in line 165 the amplitude is added. If I understand this code correctly, this means that if multiple source bins are written to the same target bin, due to the pitch being lowered, then only the highest "true" frequency is written.

I am aware that the source code in a famous article about this method does this as well, but this feels wrong to me. I believe it is probably better to do some form of averaging, for example a weighted average of the incoming frequencies using their corresponding amplitudes. This will consume more processing power, but it should be possible to do something not too heavy, for example using an arena allocator with a capacity equal to the number of processed bins.

I submitted a similar issue to the pvoc/pvoc-plugins crates (nwoeanhinnogaehr/pvoc-plugins#1), which implements a similar algorithm.

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