Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

delayline() is called twice for every impulse response in ir_wfs() #116

Open
hagenw opened this issue Dec 6, 2016 · 3 comments
Open

delayline() is called twice for every impulse response in ir_wfs() #116

hagenw opened this issue Dec 6, 2016 · 3 comments

Comments

@hagenw
Copy link
Member

hagenw commented Dec 6, 2016

This is a follow up on #115.

There @VeraE wrote that delayline() gets called several times:

  1. when calculating the driving function,
  2. in ir_correct_distance()

One way to improve this might be to let ir_correct_distance() return delay and weight instead of the actual shifted impulse response. The downside is that this would complicate how get_ir() works as this would then need to return the unmodified impulse response and the delay and weight. I guess in this case it would even be better to remove ir_correct_distance() from get_ir() and apply it somewhere else.

Maybe we find a good solution for this, but in my opinion it would be also ok, to stay with the current state.

@VeraE
Copy link
Member

VeraE commented Dec 6, 2016

The same problem applies to ssr_brs_wfs().

@VeraE
Copy link
Member

VeraE commented Dec 6, 2016

I would not want to change how get_ir() works either. But I have the following suggestion: The only delay that should be returned from ir_correct_distance() is the one that can be caused by delayline(), I think. So this should be returned from ir_correct_distance() to get_ir() to ir_generic() where it can be added to the delay returned by driving_function_imp_wfs(). What do you think?

@hagenw
Copy link
Member Author

hagenw commented Dec 6, 2016

Ah ok, now I see the real problem. I thought it was just a problem performance wise. But the problem is of course that delayline() can add a processing delay already inside ir_correct_distance(). So the only solution seems indeed to return that delay in ir_correct_distance() and pass it on.
I do not like that very much as it add a returning parameter to get_ir() that you would not expect there, but I have no better proposal at the moment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants