我是 Linux 上 GNU Octave 6.2.0 的新手,我正在尝试使用“并行”包来使用我机器上的 24 个线程。
我有一个数组 ( array1
),它有大约 500,000 行或值(1 列),对于数组的每个成员,我想应用一个 log10 函数,如下所示:
test = 10*log10(array1.^2); % this works
我尝试像这样使用并行包:
test = pararrayfun(24, @(array1) 10*log10(array1.^2), array1, "Vectorized", 1 "ChunksPerProc", 1); % this fails
但我得到了错误(重复很多次):
Could not save variable
Could not load variable
我还尝试data-smoothing
使用并行的跨度 100 将“平滑”函数(从)应用于数组,但这也失败了:
test2 = smooth(array1,100); % this works fine
test2 = pararrayfun(24, @(array1) smooth(array1,100), array1); % this fails
任何人都可以帮助我正确使用上述两个示例的“并行”语法吗?
非常感谢 !!