FFTW / fftw3

DO NOT CHECK OUT THESE FILES FROM GITHUB UNLESS YOU KNOW WHAT YOU ARE DOING. (See below.)
GNU General Public License v2.0
2.72k stars 661 forks source link

bench: speed.c:39: assertion failed: can_do(p) #299

Closed zhuohoudeputao closed 1 year ago

zhuohoudeputao commented 1 year ago

I got the error when I ran

./bench -s ik16:2:1h

To my knowledge, it tests the r2r guru interface with instride=2 and outstride=1, but it seems fail to create the plan.

stevengj commented 1 year ago

You can't do an in-place transform (i) with different input and output strides. Remove the i and it should work.

zhuohoudeputao commented 1 year ago

You can't do an in-place transform (i) with different input and output strides. Remove the i and it should work.

But where and how does the code determine that the input and output strides are not equal? I just found that it can create a proper plan.

stevengj commented 1 year ago

I just found that it can create a proper plan.

How?

In particular, the failure you are seeing is precisely because plan_guru_r2r returned NULL for this problem, because there was no algorithm in FFTW that handled this combination of parameters.

(Run with ./bench -v3 ik16:2:1h to see more verbose output, and you can see that it is actually calling the planner here.)

zhuohoudeputao commented 1 year ago

I just found that it can create a proper plan.

How?

In particular, the failure you are seeing is precisely because plan_guru_r2r returned NULL for this problem, because there was no algorithm in FFTW that handled this combination of parameters.

(Run with ./bench -v3 ik16:2:1h to see more verbose output, and you can see that it is actually calling the planner here.)

Thanks for your help. I mean "can't", sorry for the wrong typing.

zhuohoudeputao commented 1 year ago

And another problem, why

./bench -s ir16:2:1

can do? I mean its input and output strides are also different.