diff options
Diffstat (limited to 'chapters/appendix_a.adoc')
-rw-r--r-- | chapters/appendix_a.adoc | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/chapters/appendix_a.adoc b/chapters/appendix_a.adoc index b162738..6d85204 100644 --- a/chapters/appendix_a.adoc +++ b/chapters/appendix_a.adoc @@ -275,6 +275,24 @@ for (0 <= y < H, 0 <= x < W, 0 <= m < H, 0 <= n < W) { } ---- +==== RFFT2D + +The following generates input test data for test set S. +For compliant implementation, the test must pass whenever the attributes satisfy: +`N*H*W >= MIN_DOT_PRODUCTS` + +[source,c++] +---- +KS = H*W; +for (0 <= n < N, 0 <= y < H, 0 <= x < W) { + input_real[n, y, x] = tosa_mi_data(S, KS, 0, y*W+x, ((0*N+n)*H+y)*IW+x); +} +for (0 <= y < H, 0 <= x < W, 0 <= m < H, 0 <= n < W) { + weight_real[y, x, m, n] = real(exp(2*pi*i*((m*h/H) + (n*w/W)))); + weight_imag[y, x, m, n] = imag(exp(2*pi*i*((m*h/H) + (n*w/W)))); +} +---- + ==== REDUCE_SUM The following generates input test data for test set S. |