I tried PORC EQ this morning thanks to the help of Greenm01. First listen is very promising, I'll get to experiment with it more later this week and will report back here. Well worth a try, I'd say.
Hi all,
before trying PORC on my speakers, I did a simulation.
Hereunder are :
my home left speaker without correction / same speaker with DRC-FIR normal correction / convolved response with PORC
Step responses as above, DRC corrects phase response but PORC doesn't
Phase responses compared ( the blue is DRC-FIR corrected)
As PORC doesn't have microphone curve compensation, please forget response above 12kHz (I couldn't compensate for this yet)
Nice work, PORC seems very promising. I'll have to take time to listen and compare now.
before trying PORC on my speakers, I did a simulation.
Hereunder are :
my home left speaker without correction / same speaker with DRC-FIR normal correction / convolved response with PORC

Step responses as above, DRC corrects phase response but PORC doesn't

Phase responses compared ( the blue is DRC-FIR corrected)

As PORC doesn't have microphone curve compensation, please forget response above 12kHz (I couldn't compensate for this yet)
Nice work, PORC seems very promising. I'll have to take time to listen and compare now.
Last edited:
Can you please explain how the DRC-FIR phase response is a correction, based on these graphs? There exists no convenient test that delivers an easily understood quality rating for phase. Given our insensitivity to phase, the real question should be: does it matter in a normal listening environment?DRC corrects phase response but PORC doesn't
I didn't include mic compensation in PORC becuase the software I use (Room EQ Wizard) already compensates for it.As PORC doesn't have microphone curve compensation, please forget response above 12kHz (I couldn't compensate for this yet)
Thanks. I would like this to be a community project; open to improvements and suggestions.Nice work, PORC seems very promising. I'll have to take time to listen and compare now.
The step response in the middle is the one corrected with DRC-FIR and shows a corrected phase response. In the lower picture, the blue curve is the DRC-FIR phase and it is mostly flat, showing correction compared to the uncorrected green one.Can you please explain how the DRC-FIR phase response is a correction, based on these graphs?
But I agree with you, phase response is far less important than amplitude response.
Does it mean that REW can export with mic compensation ?I didn't include mic compensation in PORC becuase the software I use (Room EQ Wizard) already compensates for it.
Sometime ago I did a GUI for DRC-FIR, so I just added PORC calculation, but, sorry, only for Windows and no real manual : http://www.ohl.to/audio/downloads/align2.zipI would like this to be a community project; open to improvements and suggestions.
Last edited:
HOLMImpulse certainly can. That's what I used.Does it mean that REW can export with mic compensation ?
How do you know that the DRC-FIR "correction" is true to the uncorrected input? Based on the second graph, neither PORC nor DRC-FIR look like (visually) the uncorrected phase.The step response in the middle is the one corrected with DRC-FIR and shows a corrected phase response.
Yes.Does it mean that REW can export with mic compensation?
That's interesting. I've used some of your VST plugins before and I like your GUI. I haven't had time to look your PORC plugin, but that would be great if PORC had a user friendly front-end. It would be even better if it was a standalone package without having to manually install all the Python dependencies.Sometime ago I did a GUI for DRC-FIR, so I just added PORC calculation
Hello Greenm01,
Just received my OpenDRC and made some tests.
I use Align2 as a GUI frontend http://www.ohl.to/audio/downloads/align2.zip, and I use the target files of DRC-FIR.
Everything works with PORC but not the target function. With mostly flat curves, no problem, but when you try to compensate for mic correction or choose curves with some boost in low frequencies, then you can get strange results, ie here is PORC with bk-3-subultra-spline-48.0.txt
Any clue ? (I'm not a Python user but I will try to understand).
Anyway, with PORC, you've brought us a very nice tool..
Just received my OpenDRC and made some tests.
I use Align2 as a GUI frontend http://www.ohl.to/audio/downloads/align2.zip, and I use the target files of DRC-FIR.
Everything works with PORC but not the target function. With mostly flat curves, no problem, but when you try to compensate for mic correction or choose curves with some boost in low frequencies, then you can get strange results, ie here is PORC with bk-3-subultra-spline-48.0.txt

Any clue ? (I'm not a Python user but I will try to understand).
Anyway, with PORC, you've brought us a very nice tool..
error/bug
I purposly did not include microphone compensation in PORC because I already have it included with my recording software (Room EQ Wizard).
In regard to the target curve error there may be a bug or improvement that I can make to my spline function in Python. Thanks for pointing this out. Will you please post 'bk-3-subultra-spline-48.0.txt' so I can test it myself?
Any clue ? (I'm not a Python user but I will try to understand).Anyway, with PORC, you've brought us a very nice tool..
I purposly did not include microphone compensation in PORC because I already have it included with my recording software (Room EQ Wizard).
In regard to the target curve error there may be a bug or improvement that I can make to my spline function in Python. Thanks for pointing this out. Will you please post 'bk-3-subultra-spline-48.0.txt' so I can test it myself?
Hello,
here is a test target where I'd like to keep a bit of boost in lower frequencies :
30 -6
40 0
50 4
400 0
3000 0
10000 -2
18000 -6
here is the result !
now a bit modified
10 -60
30 -6
40 0
50 4
400 0
3000 0
10000 -2
18000 -6
20000 -60
it gets better but the bass boost is nowhere :
Spline curve calculations are allways tricky : would it be possible to avoid splines ?
here is a test target where I'd like to keep a bit of boost in lower frequencies :
30 -6
40 0
50 4
400 0
3000 0
10000 -2
18000 -6
here is the result !

now a bit modified
10 -60
30 -6
40 0
50 4
400 0
3000 0
10000 -2
18000 -6
20000 -60
it gets better but the bass boost is nowhere :

Spline curve calculations are allways tricky : would it be possible to avoid splines ?
JL, I did a bit of experimenting with PORC and with "by hand". Both seemed to work pretty well.
To do the correction by hand, I took a measurement with HOLMImpluse then combined that (in HOLM) with my target response. I don't remember which math function I used.
Once that done, I exported a 1/6 octave FR, then re-imported it so that that the FR had the smoothing built in. Not sure that step as necessary, it might not be.
From there I exported the impulse wave for use in a convolver. It worked well. Basically it's doing the same thing as PORC, but with a simple 1/6 octave smoothing. You could choose other smoothing, of course. More steps to go thru than PORC, of course.
Can't say which was better, I didn't do enough listening or measuring. But they did sound similar.
To do the correction by hand, I took a measurement with HOLMImpluse then combined that (in HOLM) with my target response. I don't remember which math function I used.
Once that done, I exported a 1/6 octave FR, then re-imported it so that that the FR had the smoothing built in. Not sure that step as necessary, it might not be.
From there I exported the impulse wave for use in a convolver. It worked well. Basically it's doing the same thing as PORC, but with a simple 1/6 octave smoothing. You could choose other smoothing, of course. More steps to go thru than PORC, of course.
Can't say which was better, I didn't do enough listening or measuring. But they did sound similar.
curve fitting
I appreciate you pointing this problem out. I will have to dive back into the code and research a better solution: it's definitely something that can be solved.
Do you recommend a particular method or algorithm vs spline?
Spline curve calculations are allways tricky : would it be possible to avoid splines ?
I appreciate you pointing this problem out. I will have to dive back into the code and research a better solution: it's definitely something that can be solved.
Do you recommend a particular method or algorithm vs spline?
I would prefer a PCHIP interpolation, see :
http://www.mathworks.com/moler/interp.pdf
http://www.mathworks.fr/help/techdoc/ref/pchip.html
because the points you define are real "corners" for the curve. Spline curves are smoother but can easily give values out of the wished limits.
http://www.mathworks.com/moler/interp.pdf
http://www.mathworks.fr/help/techdoc/ref/pchip.html
because the points you define are real "corners" for the curve. Spline curves are smoother but can easily give values out of the wished limits.
I just had a quick review of scipy docs and seems that an equivalent to matlab's pchip doesn't exist.
A while back this was posted this to a sourceforge mailing list for matplotlib but I've not had time to review it thoroughly to know if it still works or is of use directly in porc without rework I did see some discussion on merging it to mpl but I'm not sure if this has happened or not.
Interesting discussion guys, when I get home from in a few hours I'll have a read and post up anything I can find.
A while back this was posted this to a sourceforge mailing list for matplotlib but I've not had time to review it thoroughly to know if it still works or is of use directly in porc without rework I did see some discussion on merging it to mpl but I'm not sure if this has happened or not.
Interesting discussion guys, when I get home from in a few hours I'll have a read and post up anything I can find.
I just had a quick review of scipy docs and seems that an equivalent to matlab's pchip doesn't exist
Octave, the open source version of MATLAB, has a pchip function. See attached script from the Octave code base. It's just a matter of porting the function over to Python.
I'll try to set aside some time within the next few days to get it done.... unless someone else beats me to it

Attachments
target curve fix
I believe the target curve problem is fixed. Interpolation is not an ideal solution but it seems to work fairly well. If I'm not mistaken this is also the method DRC-FIR employs?
Another option is to simply target a flat curve and use parametric equalization further down the chain. I know this is fairly trivial if one uses OpenDRC or MiniDSP.
Please let me know if anyone finds any other problems or bugs.
I believe the target curve problem is fixed. Interpolation is not an ideal solution but it seems to work fairly well. If I'm not mistaken this is also the method DRC-FIR employs?
Another option is to simply target a flat curve and use parametric equalization further down the chain. I know this is fairly trivial if one uses OpenDRC or MiniDSP.
Please let me know if anyone finds any other problems or bugs.
It appears the latest version of Scipy moved the fft and ifft functions into the scipy.fftpack package. I still have 0.9 installed on my machine where it's located in scipy.signal
I made the update and pushed the revision to Github. It works on my end. Please let me know if you have any other version issues.
I made the update and pushed the revision to Github. It works on my end. Please let me know if you have any other version issues.
Quick and great job Greem01,
seems that everything works fine now, including targets !
I'll have to test more but it's late for me now.
Thanks a lot !
seems that everything works fine now, including targets !
I'll have to test more but it's late for me now.
Thanks a lot !
I believe the target curve problem is fixed. Interpolation is not an ideal solution but it seems to work fairly well. If I'm not mistaken this is also the method DRC-FIR employs?
Another option is to simply target a flat curve and use parametric equalization further down the chain. I know this is fairly trivial if one uses OpenDRC or MiniDSP.
Please let me know if anyone finds any other problems or bugs.
I just noticed in the update to SciPy 0.11 (released today) that there is some improvements/additions to the interpolate tools - SciPy 0.11.0 Release Notes — SciPy v0.12.dev Reference Guide (DRAFT)
Actually that link is a bit odd - try this - http://docs.scipy.org/doc/scipy/reference/release.0.11.0.html
Also note that there is change to behaviour of the univariate spline in 0.11, it now returns an array, I haven't had a chance to test how this might affect current porc code but worth pointing out that people not wanting to get their hands dirty shouldn't upgrade to 0.11 until that is tested.
Last edited:
- Home
- Source & Line
- Digital Line Level
- Python Open Room Correction (PORC)