gpuRIR icon indicating copy to clipboard operation
gpuRIR copied to clipboard

RIR output filtering low frequencies

Open sagyHarpaz opened this issue 4 years ago • 2 comments

Hi.

Is there an option to avoid low frequencies filtering?

sagyHarpaz avatar Sep 08 '20 06:09 sagyHarpaz

Hi,

gpuRIR doesn't implement any kind of low frequency filtering. Instead, it uses negative reflection coefficients to get a symmetric RIR (you can find more information about it in the section 2.2.2 of the paper). The library doesn't include an option to turn off this feature.

If you really need a RIR with all its reflections positive, you should be able to get by it cloning the repository, deleting the minus signs in lines 272-277 of gpuRIR_cuda.cu, and compiling and installing the library using python setup.py install. I've never tried it, but I think it should work.

https://github.com/DavidDiazGuerra/gpuRIR/blob/e66215dc6433b6f77495f9c8e764c1f750debc51/src/gpuRIR_cuda.cu#L272-L277

DavidDiazGuerra avatar Sep 08 '20 07:09 DavidDiazGuerra

You could also try to install the library as it is and just call simulateRIR using negative reflection coefficients so they become positive inside the CUDA implementation. I don't know if there is any part of the code that could crash or generate incorrect results doing so.

DavidDiazGuerra avatar Sep 08 '20 07:09 DavidDiazGuerra