From d1bf6fe5d1aa976d0456697a303c1b186bf02da6 Mon Sep 17 00:00:00 2001 From: Christophe Favergeon Date: Mon, 30 Jan 2023 07:52:04 +0100 Subject: [PATCH] Update compute graph nodes to remove overriding issue. --- ComputeGraph/cg/nodes/cpp/CFFT.h | 9 ++++++--- ComputeGraph/cg/nodes/cpp/ICFFT.h | 9 ++++++--- ComputeGraph/cg/nodes/cpp/InterleavedStereoToMono.h | 9 ++++++--- ComputeGraph/cg/nodes/cpp/MFCC.h | 12 ++++++++---- ComputeGraph/cg/nodes/cpp/NullSink.h | 2 +- ComputeGraph/cg/nodes/cpp/OverlapAndAdd.h | 3 ++- ComputeGraph/cg/nodes/cpp/SlidingBuffer.h | 3 ++- ComputeGraph/cg/nodes/cpp/StreamingSink.h | 2 +- ComputeGraph/cg/nodes/cpp/StreamingSource.h | 3 ++- ComputeGraph/cg/nodes/cpp/ToComplex.h | 3 ++- ComputeGraph/cg/nodes/cpp/ToReal.h | 3 ++- ComputeGraph/cg/nodes/cpp/Unzip.h | 3 ++- ComputeGraph/cg/nodes/cpp/Zip.h | 3 ++- ComputeGraph/cg/nodes/cpp/host/FileSink.h | 2 +- ComputeGraph/cg/nodes/cpp/host/FileSource.h | 3 ++- 15 files changed, 45 insertions(+), 24 deletions(-) diff --git a/ComputeGraph/cg/nodes/cpp/CFFT.h b/ComputeGraph/cg/nodes/cpp/CFFT.h index 2359b04a..043c86a4 100644 --- a/ComputeGraph/cg/nodes/cpp/CFFT.h +++ b/ComputeGraph/cg/nodes/cpp/CFFT.h @@ -57,7 +57,8 @@ public: return(0); }; - int run(){ + int run() override + { float32_t *a=this->getReadBuffer(); float32_t *b=this->getWriteBuffer(); memcpy((void*)b,(void*)a,inputSize*sizeof(float32_t)); @@ -96,7 +97,8 @@ public: return(0); }; - int run(){ + int run() override + { float16_t *a=this->getReadBuffer(); float16_t *b=this->getWriteBuffer(); memcpy((void*)b,(void*)a,inputSize*sizeof(float16_t)); @@ -134,7 +136,8 @@ public: return(0); }; - int run(){ + int run() override + { q15_t *a=this->getReadBuffer(); q15_t *b=this->getWriteBuffer(); memcpy((void*)b,(void*)a,inputSize*sizeof(q15_t)); diff --git a/ComputeGraph/cg/nodes/cpp/ICFFT.h b/ComputeGraph/cg/nodes/cpp/ICFFT.h index 01f1f2ba..59def60e 100644 --- a/ComputeGraph/cg/nodes/cpp/ICFFT.h +++ b/ComputeGraph/cg/nodes/cpp/ICFFT.h @@ -57,7 +57,8 @@ public: return(0); }; - int run(){ + int run() override + { float32_t *a=this->getReadBuffer(); float32_t *b=this->getWriteBuffer(); memcpy((void*)b,(void*)a,inputSize*sizeof(float32_t)); @@ -96,7 +97,8 @@ public: return(0); }; - int run(){ + int run() override + { float16_t *a=this->getReadBuffer(); float16_t *b=this->getWriteBuffer(); memcpy((void*)b,(void*)a,inputSize*sizeof(float16_t)); @@ -135,7 +137,8 @@ public: return(0); }; - int run(){ + int run() override + { q15_t *a=this->getReadBuffer(); q15_t *b=this->getWriteBuffer(); memcpy((void*)b,(void*)a,inputSize*sizeof(q15_t)); diff --git a/ComputeGraph/cg/nodes/cpp/InterleavedStereoToMono.h b/ComputeGraph/cg/nodes/cpp/InterleavedStereoToMono.h index 6bec929a..8192182f 100644 --- a/ComputeGraph/cg/nodes/cpp/InterleavedStereoToMono.h +++ b/ComputeGraph/cg/nodes/cpp/InterleavedStereoToMono.h @@ -52,7 +52,8 @@ public: return(0); }; - int run(){ + int run() override + { q15_t *a=this->getReadBuffer(); q15_t *b=this->getWriteBuffer(); for(int i = 0; igetReadBuffer(); q31_t *b=this->getWriteBuffer(); for(int i = 0; igetReadBuffer(); float32_t *b=this->getWriteBuffer(); for(int i = 0; igetReadBuffer(); float32_t *b=this->getWriteBuffer(); arm_mfcc_f32(mfccConfig,a,b,memory.data()); @@ -112,7 +113,8 @@ public: return(0); }; - int run(){ + int run() override + { float16_t *a=this->getReadBuffer(); float16_t *b=this->getWriteBuffer(); arm_mfcc_f16(mfccConfig,a,b,memory.data()); @@ -150,7 +152,8 @@ public: return(0); }; - int run(){ + int run() override + { q31_t *a=this->getReadBuffer(); q31_t *b=this->getWriteBuffer(); arm_mfcc_q31(mfccConfig,a,b,memory.data()); @@ -187,7 +190,8 @@ public: return(0); }; - int run(){ + int run() override + { q15_t *a=this->getReadBuffer(); q15_t *b=this->getWriteBuffer(); arm_mfcc_q15(mfccConfig,a,b,memory.data()); diff --git a/ComputeGraph/cg/nodes/cpp/NullSink.h b/ComputeGraph/cg/nodes/cpp/NullSink.h index 57d9592c..cde56640 100644 --- a/ComputeGraph/cg/nodes/cpp/NullSink.h +++ b/ComputeGraph/cg/nodes/cpp/NullSink.h @@ -46,7 +46,7 @@ public: return(0); }; - int run() + int run() override { IN *b=this->getReadBuffer(); diff --git a/ComputeGraph/cg/nodes/cpp/OverlapAndAdd.h b/ComputeGraph/cg/nodes/cpp/OverlapAndAdd.h index 1c20769a..79986b8e 100644 --- a/ComputeGraph/cg/nodes/cpp/OverlapAndAdd.h +++ b/ComputeGraph/cg/nodes/cpp/OverlapAndAdd.h @@ -52,7 +52,8 @@ public: return(0); }; - int run(){ + int run() override + { int i; IN *a=this->getReadBuffer(); IN *b=this->getWriteBuffer(); diff --git a/ComputeGraph/cg/nodes/cpp/SlidingBuffer.h b/ComputeGraph/cg/nodes/cpp/SlidingBuffer.h index ff1d833c..0b7621ae 100644 --- a/ComputeGraph/cg/nodes/cpp/SlidingBuffer.h +++ b/ComputeGraph/cg/nodes/cpp/SlidingBuffer.h @@ -52,7 +52,8 @@ public: return(0); }; - int run(){ + int run() override + { IN *a=this->getReadBuffer(); IN *b=this->getWriteBuffer(); memcpy((void*)b,(void*)memory.data(),overlap*sizeof(IN)); diff --git a/ComputeGraph/cg/nodes/cpp/StreamingSink.h b/ComputeGraph/cg/nodes/cpp/StreamingSink.h index 3765fbcb..00e5dd40 100644 --- a/ComputeGraph/cg/nodes/cpp/StreamingSink.h +++ b/ComputeGraph/cg/nodes/cpp/StreamingSink.h @@ -49,7 +49,7 @@ public: return(0); }; - int run() + int run() override { IN *b=this->getReadBuffer(); diff --git a/ComputeGraph/cg/nodes/cpp/StreamingSource.h b/ComputeGraph/cg/nodes/cpp/StreamingSource.h index 343b36b3..73bb9949 100644 --- a/ComputeGraph/cg/nodes/cpp/StreamingSource.h +++ b/ComputeGraph/cg/nodes/cpp/StreamingSource.h @@ -49,7 +49,8 @@ public: return(0); }; - int run(){ + int run() override + { OUT *b=this->getWriteBuffer(); /* Try to reserve a buffer. If no buffer is available, the task running diff --git a/ComputeGraph/cg/nodes/cpp/ToComplex.h b/ComputeGraph/cg/nodes/cpp/ToComplex.h index e048416a..5498ef1d 100644 --- a/ComputeGraph/cg/nodes/cpp/ToComplex.h +++ b/ComputeGraph/cg/nodes/cpp/ToComplex.h @@ -56,7 +56,8 @@ public: return(0); }; - int run(){ + int run() override + { IN *a=this->getReadBuffer(); IN *b=this->getWriteBuffer(); for(int i=0;igetReadBuffer(); IN *b=this->getWriteBuffer(); for(int i=0;igetReadBuffer(); IN *b1=this->getWriteBuffer1(); IN *b2=this->getWriteBuffer2(); diff --git a/ComputeGraph/cg/nodes/cpp/Zip.h b/ComputeGraph/cg/nodes/cpp/Zip.h index 6447c075..33c2500b 100644 --- a/ComputeGraph/cg/nodes/cpp/Zip.h +++ b/ComputeGraph/cg/nodes/cpp/Zip.h @@ -52,7 +52,8 @@ public: return(0); }; - int run(){ + int run() override + { IN *a1=this->getReadBuffer1(); IN *a2=this->getReadBuffer2(); IN *b=this->getWriteBuffer1(); diff --git a/ComputeGraph/cg/nodes/cpp/host/FileSink.h b/ComputeGraph/cg/nodes/cpp/host/FileSink.h index bda7c34d..dd6ced15 100644 --- a/ComputeGraph/cg/nodes/cpp/host/FileSink.h +++ b/ComputeGraph/cg/nodes/cpp/host/FileSink.h @@ -46,7 +46,7 @@ public: return(0); }; - int run() + int run() override { IN *b=this->getReadBuffer(); diff --git a/ComputeGraph/cg/nodes/cpp/host/FileSource.h b/ComputeGraph/cg/nodes/cpp/host/FileSource.h index 70252791..5ebf29dc 100644 --- a/ComputeGraph/cg/nodes/cpp/host/FileSource.h +++ b/ComputeGraph/cg/nodes/cpp/host/FileSource.h @@ -57,7 +57,8 @@ public: return(0); }; - int run(){ + int run() override + { string str; int i; float32_t *b=this->getWriteBuffer();