Offline Measurements: how to avoid sub-sample shifting and how to set IR start to exact sample # ?

KSTR

New Member
Thread Starter
Joined
Jun 7, 2019
Messages
49
This is for extreme precision electrical measurements needed for subtractive analysis so tiny details do count, in this case I need to have precision positioning of the pulse to reflect the DUT's transfer function (including any time-of-flight etc) fully "as is".

First question: When doing sweep imports (or even in the general case), does setting "t=0 at IR start" in the measurements panel guarantee that no sub-sample shifting is applied?
If so, wouldn't it be better to have an unlinked selection for the import dialog, to avoid the hidden dependency (took me days to figure it out)?

Second question: for the same reason of avoiding (hidden/uncontrolled) sub-sample shifts, how can a thusly imported IR be shifted by an *exact* integer sample multiple? I found that the empirical "IR start" often has some +-1 sample variation even for almost (99.99%) identical import data and I want to compensate that before applying windows. Using "t=0 at cursor" doesn't seem to be useful as the cursor cannot be set on an exact sample as far as I can see, so maybe a future "shift N samples" additional option for positioning, with N required to be an integer?
 

John Mulcahy

REW Author
Joined
Apr 3, 2017
Messages
7,212
V5.19 has an Analysis preference to disable sub-sample timing adjustments and a control to move the start time of an impulse by an integer number of samples. Those features were removed in V5.20 in the course of reducing clutter in the interface.

Fractional sample timing adjustments will be applied to determine t=0 if a timing reference is used. When not using a timing reference there are 3 choices for the t=0 position of the measured impulse response: (1) Set t=0 at IR peak will place t=0 at the exact position of the peak of the IR, determined by interpolating an oversampled version of the IR; (2) Set t=0 at IR start will place the t=0 point at the sample before the IR first exceeds 10% of the peak level; (3) Set t=0 from delay estimate will use cross-correlation with a minimum phase version of the impulse to estimate and remove any time delay. I have added a note to the help to explain that.
 

KSTR

New Member
Thread Starter
Joined
Jun 7, 2019
Messages
49
OK, understood. So I would need to use V5.19 for this specific task... hoping that will not cause other issues. The sweeps generated with V5.20RC4 would be compatible, as most important question?
Do you see any way to make the 10% threshold adjustable/selectable? That would fix the issue completely...
 

John Mulcahy

REW Author
Joined
Apr 3, 2017
Messages
7,212
To use V5.19 the sweep file must be generated by V5.19. The 10% threshold is the usual definition applied for acoustic measurements, lower thresholds can end up with incorrect start points from preringing or noise. Limiting resolution to samples will usually mean that high frequency phase is not correct though, in the sense of being able to accurately remove pure time delays.
 

KSTR

New Member
Thread Starter
Joined
Jun 7, 2019
Messages
49
Yes I do understand that normally, with no timing ref, one would like to have the IR automatically positioned so that the phase is about correct, and that needs sub-sample shift.
As for the threshold, a higher one would do (30...50%), not a lower.

Would a workaround be possible by exporting non-windowed IR, manual shift, re-import as impulse (how is the start determined there, btw?), applying windows on the now correctly aligned data, export?
 

John Mulcahy

REW Author
Joined
Apr 3, 2017
Messages
7,212
For IR imports t=0 is set either at the peak or at the first sample according to the Analysis preference setting.
 

KSTR

New Member
Thread Starter
Joined
Jun 7, 2019
Messages
49
Thanks, I'll try things out and see what I get...
 

KSTR

New Member
Thread Starter
Joined
Jun 7, 2019
Messages
49
OK, it's working as expected with the IR re-imported and "t=0 at impulse peak" setting (in "analysis" tab) which in this case means the highest sample absolute value, not the peak of the sinc-reconstructed waveform... which is exactly what I wanted. Problem solved ;-)
 

KSTR

New Member
Thread Starter
Joined
Jun 7, 2019
Messages
49
But a small and rather irrelevant bug (?), the "IR-Oversampler" setting does not seem to affect "IR import" display (only real-time and offline sweep-generated IR's show a changes), IR import always seems to use the "none" setting (Hermite Interpolation).
 
Top Bottom