Commit 619fa229 authored by Dipl.-Ing. Jonas Stienen's avatar Dipl.-Ing. Jonas Stienen
Browse files

Big cleanup, moving a lot of tests into subfolders

parent df301757
......@@ -55,6 +55,7 @@ set( ITADSPSources
"src/ITAIIRFilterEngine.cpp"
"src/ITAThirdOctaveFilterbank.cpp"
"src/ITAThirdOctaveFilterbankIIR.cpp"
"src/ITAThirdOctaveFilterbankFIR.cpp"
"src/ITAThirdOctaveFIRFilterGenerator.cpp"
"src/ITAThirdOctaveFilterbankIIRCoefficients.h"
"src/ITAVariableDelayLine.cpp"
......
......@@ -22,78 +22,26 @@
#include <ITAThirdOctaveFilterbank.h>
#include <ITAThirdOctaveFIRFilterGenerator.h>
#include <ITAUPConvolution.h>
#include <ITAUPFilter.h>
#include <ITAFastMath.h>
#include <cassert>
class ITAUPConvolution;
//! Terzfilterbank mittels Dynamic Single-Channel Blockfalter (FIR Filter)
class ITA_DSP_API CITAThirdOctaveFilterbankFIR : public CITAThirdOctaveFilterbank
{
public:
inline CITAThirdOctaveFilterbankFIR( const double dSampleRate, const int iBlockLength )
: m_pfFilter( nullptr )
, m_pGenerator( nullptr )
, m_pConvolver( nullptr )
{
m_iBlocklength = iBlockLength;
// [fwe] Hier wird die Filterlänge für Directivities festgelegt
m_iFilterLength = 128;
m_pfFilter = fm_falloc( m_iFilterLength, true );
m_pGenerator = new CITAThirdOctaveFIRFilterGenerator( dSampleRate, m_iFilterLength );
m_pConvolver = new ITAUPConvolution( iBlockLength, m_iFilterLength );
m_pConvolver->SetFilterExchangeFadingFunction( ITABase::FadingFunction::COSINE_SQUARE );
m_pConvolver->SetFilterCrossfadeLength( 32 );
SetIdentity( false );
}
inline virtual ~CITAThirdOctaveFilterbankFIR()
{
fm_free( m_pfFilter );
delete m_pGenerator;
delete m_pConvolver;
}
inline virtual void SetIdentity( const bool bSmoothChangeover )
{
ITAUPFilter* pFilter = m_pConvolver->RequestFilter();
int iLatency = m_pGenerator->GetLatency();
assert( iLatency < m_iFilterLength );
fm_zero( m_pfFilter, m_iFilterLength );
m_pfFilter[ iLatency ] = 1;
pFilter->Load( m_pfFilter, m_iFilterLength );
m_pConvolver->ExchangeFilter( pFilter, ( bSmoothChangeover ? ITABase::FadingFunction::COSINE_SQUARE : ITABase::FadingFunction::SWITCH ) );
pFilter->Release(); // Auto-release
}
inline virtual void SetMagnitudes( const ITABase::CThirdOctaveGainMagnitudeSpectrum& oMags, const bool bSmoothChangeover = true )
{
m_pGenerator->GenerateFilter( oMags, m_pfFilter );
ITAUPFilter* pFilter = m_pConvolver->RequestFilter();
pFilter->Load( m_pfFilter, m_iFilterLength );
m_pConvolver->ExchangeFilter( pFilter, ( bSmoothChangeover ? ITABase::FadingFunction::COSINE_SQUARE : ITABase::FadingFunction::SWITCH ) );
pFilter->Release(); // Auto-release
}
inline int GetLatency() const
{
return m_pGenerator->GetLatency();
}
CITAThirdOctaveFilterbankFIR( const double dSampleRate, const int iBlockLength );
inline virtual void Clear()
{
m_pConvolver->clear();
SetIdentity( true );
}
virtual ~CITAThirdOctaveFilterbankFIR();
inline virtual void Process( const float* pfInputSamples, float* pfOutputSamples )
{
m_pConvolver->Process( pfInputSamples, m_iBlocklength, pfOutputSamples, m_iBlocklength );
}
virtual void SetIdentity( const bool bSmoothChangeover = true );
virtual void SetMagnitudes( const ITABase::CThirdOctaveGainMagnitudeSpectrum& oMags, const bool bSmoothChangeover = true );
int GetLatency() const;
virtual void Clear();
virtual void Process( const float* pfInputSamples, float* pfOutputSamples );
private:
int m_iBlocklength;
......
......@@ -16,4 +16,68 @@
*
*/
#include "VAThirdOctaveFilterbank.h"
#include "ITAThirdOctaveFilterbankFIR.h"
#include <ITAUPConvolution.h>
CITAThirdOctaveFilterbankFIR::CITAThirdOctaveFilterbankFIR( const double dSampleRate, const int iBlockLength )
: m_pfFilter( nullptr )
, m_pGenerator( nullptr )
, m_pConvolver( nullptr )
{
m_iBlocklength = iBlockLength;
// [fwe] Hier wird die Filterlnge fr Directivities festgelegt
m_iFilterLength = 128;
m_pfFilter = fm_falloc( m_iFilterLength, true );
m_pGenerator = new CITAThirdOctaveFIRFilterGenerator( dSampleRate, m_iFilterLength );
m_pConvolver = new ITAUPConvolution( iBlockLength, m_iFilterLength );
m_pConvolver->SetFilterExchangeFadingFunction( ITABase::FadingFunction::COSINE_SQUARE );
m_pConvolver->SetFilterCrossfadeLength( 32 );
SetIdentity( false );
}
CITAThirdOctaveFilterbankFIR::~CITAThirdOctaveFilterbankFIR()
{
fm_free( m_pfFilter );
delete m_pGenerator;
delete m_pConvolver;
}
void CITAThirdOctaveFilterbankFIR::SetIdentity( const bool bSmoothChangeover /*=true*/ )
{
ITAUPFilter* pFilter = m_pConvolver->RequestFilter();
int iLatency = m_pGenerator->GetLatency();
assert( iLatency < m_iFilterLength );
fm_zero( m_pfFilter, m_iFilterLength );
m_pfFilter[ iLatency ] = 1;
pFilter->Load( m_pfFilter, m_iFilterLength );
m_pConvolver->ExchangeFilter( pFilter, ( bSmoothChangeover ? ITABase::FadingFunction::COSINE_SQUARE : ITABase::FadingFunction::SWITCH ) );
pFilter->Release(); // Auto-release
}
void CITAThirdOctaveFilterbankFIR::SetMagnitudes( const ITABase::CThirdOctaveGainMagnitudeSpectrum& oMags, const bool bSmoothChangeover /*= true*/ )
{
m_pGenerator->GenerateFilter( oMags, m_pfFilter );
ITAUPFilter* pFilter = m_pConvolver->RequestFilter();
pFilter->Load( m_pfFilter, m_iFilterLength );
m_pConvolver->ExchangeFilter( pFilter, ( bSmoothChangeover ? ITABase::FadingFunction::COSINE_SQUARE : ITABase::FadingFunction::SWITCH ) );
pFilter->Release(); // Auto-release
}
int CITAThirdOctaveFilterbankFIR::GetLatency() const
{
return m_pGenerator->GetLatency();
}
void CITAThirdOctaveFilterbankFIR::Clear()
{
m_pConvolver->clear();
SetIdentity( true );
}
void CITAThirdOctaveFilterbankFIR::Process( const float* pfInputSamples, float* pfOutputSamples )
{
m_pConvolver->Process( pfInputSamples, m_iBlocklength, pfOutputSamples, m_iBlocklength );
}
\ No newline at end of file
......@@ -18,95 +18,9 @@ if( ITA_VISTA_BUILD_STATIC )
add_definitions( -DVISTATOOLS_STATIC -DVISTABASE_STATIC -DVISTAMATH_STATIC -DVISTAASPECTS_STATIC -DVISTAINTERPROCCOMM_STATIC )
endif( )
add_executable( ITADSPIIRFilterTest ITADSPIIRFilterTest.cpp )
target_link_libraries( ITADSPIIRFilterTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPIIRFilterTest )
vista_install( ITADSPIIRFilterTest )
vista_create_default_info_file( ITADSPIIRFilterTest )
set_property( TARGET ITADSPIIRFilterTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITADSPIIRFilterGeneratorTest ITADSPIIRFilterGeneratorTest.cpp )
target_link_libraries( ITADSPIIRFilterGeneratorTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPIIRFilterGeneratorTest )
vista_install( ITADSPIIRFilterGeneratorTest )
vista_create_default_info_file( ITADSPIIRFilterGeneratorTest )
set_property( TARGET ITADSPIIRFilterGeneratorTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITADSPBiquadTest ITADSPBiquadTest.cpp )
target_link_libraries( ITADSPBiquadTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPBiquadTest )
vista_install( ITADSPBiquadTest )
vista_create_default_info_file( ITADSPBiquadTest )
set_property( TARGET ITADSPBiquadTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITADSPVariableDelayLineTest ITADSPVariableDelayLineTest.cpp )
target_link_libraries( ITADSPVariableDelayLineTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPVariableDelayLineTest )
vista_install( ITADSPVariableDelayLineTest )
vista_create_default_info_file( ITADSPVariableDelayLineTest )
set_property( TARGET ITADSPVariableDelayLineTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITADSPSIMOVDLTest ITADSPSIMOVDLTest.cpp )
target_link_libraries( ITADSPSIMOVDLTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPSIMOVDLTest )
vista_install( ITADSPSIMOVDLTest )
vista_create_default_info_file( ITADSPSIMOVDLTest )
set_property( TARGET ITADSPSIMOVDLTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITADSPThirdOctaveFilterGeneratorTest ITADSPThirdOctaveFilterGeneratorTest.cpp )
target_link_libraries( ITADSPThirdOctaveFilterGeneratorTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPThirdOctaveFilterGeneratorTest )
vista_install( ITADSPThirdOctaveFilterGeneratorTest )
vista_create_default_info_file( ITADSPThirdOctaveFilterGeneratorTest )
set_property( TARGET ITADSPThirdOctaveFilterGeneratorTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITADSPSIMOVDLSourceInShoebox ITADSPSIMOVDLSourceInShoebox.cpp )
target_link_libraries( ITADSPSIMOVDLSourceInShoebox ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPSIMOVDLSourceInShoebox )
vista_install( ITADSPSIMOVDLSourceInShoebox )
vista_create_default_info_file( ITADSPSIMOVDLSourceInShoebox )
set_property( TARGET ITADSPSIMOVDLSourceInShoebox PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITADSPThirdOctaveFilterbankTest ITADSPThirdOctaveFilterbankTest.cpp )
target_link_libraries( ITADSPThirdOctaveFilterbankTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITADSPThirdOctaveFilterbankTest )
vista_install( ITADSPThirdOctaveFilterbankTest )
vista_create_default_info_file( ITADSPThirdOctaveFilterbankTest )
set_property( TARGET ITADSPThirdOctaveFilterbankTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_executable( ITASIMOVariableDelayLineBaseTest ITASIMOVariableDelayLineBaseTest.cpp )
target_link_libraries( ITASIMOVariableDelayLineBaseTest ${VISTA_USE_PACKAGE_LIBRARIES} )
vista_configure_app( ITASIMOVariableDelayLineBaseTest )
vista_install( ITASIMOVariableDelayLineBaseTest )
vista_create_default_info_file( ITASIMOVariableDelayLineBaseTest )
set_property( TARGET ITASIMOVariableDelayLineBaseTest PROPERTY FOLDER "ITACoreLibs/Tests/ITADSP" )
add_subdirectory( "vdl" )
add_subdirectory( "filtering" )
add_subdirectory( "generators" )
if( ITA_DSP_WITH_INTEL_MKL_SUPPORT )
add_subdirectory( "mkl" )
......
%% ITADSPThirdOctaveFilterGeneratorTest evaluation Matlab script
% Loads the FIR filters resulting from the test ITADSPThirdOctaveFilterGeneratorTest_Identity_FIR
% Requires ITA Toolbox, see http://ita-toolbox.org
ITADSPThirdOctaveFilterGeneratorTest_Identity_FIR = ita_read( 'ITADSPThirdOctaveFilterGeneratorTest_Identity_FIR.wav' );
ITADSPThirdOctaveFilterGeneratorTest_Zero_FIR = ita_read( 'ITADSPThirdOctaveFilterGeneratorTest_Zero_FIR.wav' );
ITADSPThirdOctaveFilterGeneratorTest_SingleBands_FIR = ita_read( 'ITADSPThirdOctaveFilterGeneratorTest_SingleBands_FIR.wav' );
ITADSPThirdOctaveFilterGeneratorTest_Zero_FIR.channelNames = { 'Zero' };
ITADSPThirdOctaveFilterGeneratorTest_Zero_FIR.pf
ITADSPThirdOctaveFilterGeneratorTest_Identity_FIR.channelNames = { 'Identity' };
ITADSPThirdOctaveFilterGeneratorTest_Identity_FIR.pf
ITADSPThirdOctaveFilterGeneratorTest_SingleBands_FIR.pf
#include <ITAThirdOctaveFilterbank.h>
#include <ITAAudiofileWriter.h>
#include <ITAStopWatch.h>
#include <ITASampleBuffer.h>
#include <iostream>
using namespace std;
const double g_dSampleRate = 44100;
const int g_iFilterLength = 512;
void TestThirdOctaveFilterbankIIRBiquad();
void TestThirdOctaveFilterbankIIRBurg();
void TestThirdOctaveFilterbankFIR();
int main( int, char** )
{
TestThirdOctaveFilterbankIIRBiquad();
TestThirdOctaveFilterbankIIRBurg();
TestThirdOctaveFilterbankFIR();
return 255;
}
void TestThirdOctaveFilterbankIIRBiquad()
{
const int iSampleLength = ( 1 << 17 );
CITAThirdOctaveFilterbank* pIIRFilterbank = CITAThirdOctaveFilterbank::Create( g_dSampleRate, iSampleLength, CITAThirdOctaveFilterbank::IIR_BIQUADS_ORDER10 );
ITASampleBuffer x( iSampleLength, true );
x[ 0 ] = 1.0f;
ITABase::CThirdOctaveGainMagnitudeSpectrum oMags;
oMags.SetIdentity();
pIIRFilterbank->SetMagnitudes( oMags, false );
ITASampleBuffer y( iSampleLength );
ITAStopWatch sw;
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime identity magnitudes: " << sw.ToString() << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBiquad_Identity.wav", &y, g_dSampleRate );
y.Zero();
pIIRFilterbank->Clear();
oMags.SetZero();
pIIRFilterbank->SetMagnitudes( oMags, false );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime zero magnitude: " << sw.ToString() << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBiquad_Zeros.wav", &y, g_dSampleRate );
pIIRFilterbank->Clear();
// dB values
oMags[ 3 ] = 3.0f;
oMags[ 10 ] = -3.0f;
oMags[ 11 ] = -6.0f;
oMags[ 12 ] = -9.0f;
oMags[ 13 ] = -9.0f;
oMags[ 14 ] = -7.0f;
pIIRFilterbank->SetMagnitudes( oMags );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime real magnitudes: " << sw.ToString() << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBiquad_SomeBands.wav", &y, g_dSampleRate );
delete pIIRFilterbank;
}
void TestThirdOctaveFilterbankIIRBurg()
{
const int iSampleLength = ( 1 << 17 );
CITAThirdOctaveFilterbank* pIIRFilterbank = CITAThirdOctaveFilterbank::Create( g_dSampleRate, iSampleLength, CITAThirdOctaveFilterbank::IIR_BURG_ORDER4 );
ITASampleBuffer x( iSampleLength, true );
x[ 0 ] = 1.0f;
ITABase::CThirdOctaveGainMagnitudeSpectrum oMags;
oMags.SetIdentity();
pIIRFilterbank->SetMagnitudes( oMags, false );
ITASampleBuffer y( iSampleLength );
ITAStopWatch sw;
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime identity magnitudes: " << sw.ToString() << endl;
cout << "RMS (energy): " << y.RootMeanSquare( false ) << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBurg_Identity.wav", &y, g_dSampleRate );
y.Zero();
pIIRFilterbank->Clear();
oMags.SetIdentity();
oMags.Multiply( 0.5f );
pIIRFilterbank->SetMagnitudes( oMags, false );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime identity half energy magnitudes: " << sw.ToString() << endl;
cout << "RMS (energy): " << y.RootMeanSquare( false ) << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBurg_IdentityHalfEnergy.wav", &y, g_dSampleRate );
y.Zero();
pIIRFilterbank->Clear();
oMags.SetZero();
pIIRFilterbank->SetMagnitudes( oMags, false );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime zero magnitude: " << sw.ToString() << endl;
cout << "RMS (energy): " << y.RootMeanSquare( false ) << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBurg_Zeros.wav", &y, g_dSampleRate );
pIIRFilterbank->Clear();
// dB values
oMags[ 3 ] = 3.0f;
oMags[ 10 ] = -3.0f;
oMags[ 11 ] = -6.0f;
oMags[ 12 ] = -9.0f;
oMags[ 13 ] = -9.0f;
oMags[ 14 ] = -7.0f;
pIIRFilterbank->SetMagnitudes( oMags );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime real magnitudes: " << sw.ToString() << endl;
cout << "RMS (energy): " << y.RootMeanSquare( false ) << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBurg_SomeBands.wav", &y, g_dSampleRate );
// High pass
oMags.SetIdentity();
for( int i = 15; i >= 0; i-- )
oMags[ i ] = powf( 0.5f, 15 - i );
pIIRFilterbank->SetMagnitudes( oMags );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime high pass magnitudes: " << sw.ToString() << endl;
cout << "RMS (energy): " << y.RootMeanSquare( false ) << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_IIRBurg_HighPass.wav", &y, g_dSampleRate );
delete pIIRFilterbank;
}
void TestThirdOctaveFilterbankFIR()
{
const int iSampleLength = ( 1 << 17 );
CITAThirdOctaveFilterbank* pIIRFilterbank = CITAThirdOctaveFilterbank::Create( g_dSampleRate, iSampleLength, CITAThirdOctaveFilterbank::FIR_SPLINE_LINEAR_PHASE );
ITASampleBuffer x( iSampleLength );
x[ 0 ] = 1.0f;
ITABase::CThirdOctaveGainMagnitudeSpectrum oMags;
oMags.SetIdentity();
pIIRFilterbank->SetMagnitudes( oMags, false );
ITASampleBuffer y( iSampleLength );
ITAStopWatch sw;
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime identity magnitudes:" << sw.ToString() << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_FIR_Identity.wav", &y, g_dSampleRate );
y.Zero();
pIIRFilterbank->Clear();
oMags.SetZero();
pIIRFilterbank->SetMagnitudes( oMags, false );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime zero magnitude:" << sw.ToString() << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_FIR_Zeros.wav", &y, g_dSampleRate );
pIIRFilterbank->Clear();
// dB values
oMags[ 3 ] = 3.0f;
oMags[ 10 ] = -3.0f;
oMags[ 11 ] = -6.0f;
oMags[ 12 ] = -9.0f;
oMags[ 13 ] = -9.0f;
oMags[ 14 ] = -7.0f;
pIIRFilterbank->SetMagnitudes( oMags );
sw.start();
pIIRFilterbank->Process( x.GetData(), y.GetData() );
sw.stop();
cout << "Runtime real magnitudes:" << sw.ToString() << endl;
y.Normalize();
writeAudiofile( "ITADSPThirdOctaveFilterbankTest_FIR_SomeBands.wav", &y, g_dSampleRate );
delete pIIRFilterbank;
}
%% ITADSPThirdOctaveFilterbankTest evaluation Matlab script
% Loads the results of filterbanks from the test ITADSPThirdOctaveFilterbankTest
% Requires ITA Toolbox, see http://ita-toolbox.org
iir_ident = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBiquad_Identity.wav' );
%iir_ident.signalType = 'energy';
iir_ident.channelNames = { 'Identity' };
iir_ident.pf
test_iir_ident = ita_normalize_dat( ita_merge( ita_demosound, ita_convolve( ita_demosound, iir_ident ) ), 'allchannels', true );
test_iir_ident2 = ita_normalize_spk( ita_merge( ita_demosound, ita_convolve( ita_demosound, iir_ident ) ), 'allchannels', true );
test_iir_ident2.play
iir_zeros = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBiquad_Zeros.wav' );
iir_zeros.channelNames = { 'Zeros' };
iir_zeros.pf
%
% fdatool
%
% SOS =
%
% 1.0000 0 -1.0000 1.0000 0.2606 0.8247
% 1.0000 0 -1.0000 1.0000 -0.8148 0.8398
% 1.0000 0 -1.0000 1.0000 -0.5621 0.6067
% 1.0000 0 -1.0000 1.0000 0.0527 0.5859
% 1.0000 0 -1.0000 1.0000 -0.2483 0.5095
%
% G
%
% G =
%
% 0.2843
% 0.2843
% 0.2544
% 0.2544
% 0.2452
% 1.0000
%
ITADSPThirdOctaveFilterbankTest_IIRBiquad_Zeros = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBiquad_Zeros.wav' );
ITADSPThirdOctaveFilterbankTest_IIRBiquad_SomeBands = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBiquad_SomeBands.wav' );
ITADSPThirdOctaveFilterbankTest_IIRBiquad_Zeros.channelNames = { 'Zero' };
ITADSPThirdOctaveFilterbankTest_IIRBiquad_Zeros.pf
ITADSPThirdOctaveFilterbankTest_IIRBiquad_SomeBands.pf
%% FIR
fir_zeros = ita_read( 'ITADSPThirdOctaveFilterbankTest_FIR_Zeros.wav' );
fir_zeros.signalType = 'power';
fir_unity = ita_read( 'ITADSPThirdOctaveFilterbankTest_FIR_Identity.wav' );
fir_unity.signalType = 'power';
fir_sb = ita_read( 'ITADSPThirdOctaveFilterbankTest_FIR_SomeBands.wav' );
fir_sb.signalType = 'power';
fir_sb_unity = fir_sb.ch( 1 );
for n = 2:fir_sb.nChannels
fir_sb_unity = fir_sb_unity + fir_sb.ch( n );
end
fir_all = ita_merge( fir_zeros, fir_unity, fir_sb );
fir_all.pf
%% IIR Burg
iir_burg_zeros = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBurg_Zeros.wav' );
iir_burg_unity = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBurg_Identity.wav' );
iir_burg_unity_half = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBurg_IdentityHalfEnergy.wav' );
iir_burg_sb = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBurg_SomeBands.wav' );
iir_burg_hp = ita_read( 'ITADSPThirdOctaveFilterbankTest_IIRBurg_HighPass.wav' );