Inefficient wavedec implementation?

Hello,
I use the wden function for denoising large signals(10M points) and I would like to reduce the execution time. By profiling, I oberved that 50% of the time is spent in wavedec and more than 25% is spent in waverec:
no preallocation0.JPG
Turning my attention to wavedec, I observed that 50% of the runtime(so 25% of the total wden runtime) is spent in a line that is appending detail coefs to an array that was not preallocated in the code.
no preallocation.JPG
I suspect that the appending uses some sort of preallocation in the back(grow by factor of ... ?), but it might not be optimal.
Is there a possibility to prealocate this array(maybe based on the length of the signal and the level of decomposition)?
Thank you,
Iulian

回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeDenoising and Compression についてさらに検索

製品

リリース

R2017b

質問済み:

2019 年 7 月 8 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by