- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

I have found that if the value"prod = alpha * (len-1)/2"> ~39 (where len and alpha are arg values to the function), the functionreturns an error code and does not calculate the requested window points. The error code and string returned is (-39), "ippStsHugeWinErr: Kaiser window is too huge".

For example, for len = 40, any alpha > 1.9 causes the function error. For len = 100, alpha > 0.77 causes the error. The _64f version does not appear to have this problem.

Here is example code for len=40:

void Test_ippsWinKaiser_32f_I(void)

{

Ipp32s LEN = 40; // LEN can be varied

Ipp32f* pDst = ippsMalloc_32f(LEN);

for (Ipp32s n=0 ; n

pDst

Ipp32f beg=36.0f, end=42.0f, step=1.0f; // range to trap error, happens around prod=39

for (Ipp32f prod=beg ; prod<=end ; prod+=step) // loop thru range in steps

{

Ipp32f alpha = prod / (Ipp32f)(LEN-1)*2.0f; // calc alpha related to prod & LEN

IppStatus s=ippsWinKaiser_32f_I(pDst, LEN, alpha);

printf("Len = %i, Prod = %.5f, Alpha = %.5f", LEN, prod, alpha);

if (s != ippStsNoErr) // print when error detected.

{

printf(" ---> err=%i, msg=\\"%s\\"",

(int)s, ippGetStatusString(s));

}

printf("\\n");

}

ippsFree(pDst);

}

The output in this case is:

Len = 40, Prod = 36.00000, Alpha = 1.84615

Len = 40, Prod = 37.00000, Alpha = 1.89744

Len = 40, Prod = 38.00000, Alpha = 1.94872 ---> err=-39, msg="ippStsHugeWinErr: Kaiser window is too huge"

Len = 40, Prod = 39.00000, Alpha = 2.00000 ---> err=-39, msg="ippStsHugeWinErr: Kaiser window is too huge"

Len = 40, Prod = 40.00000, Alpha = 2.05128 ---> err=-39, msg="ippStsHugeWinErr: Kaiser window is too huge"

Len = 40, Prod = 41.00000, Alpha = 2.10256 ---> err=-39, msg="ippStsHugeWinErr: Kaiser window is too huge"

Len = 40, Prod = 42.00000, Alpha = 2.15385 ---> err=-39, msg="ippStsHugeWinErr: Kaiser window is too huge"

Link Copied

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

it's designed behavior:

#define IPP_MAX_EXP64f 308

#define IPP_MAX_EXP32f 38

#define IPP_HUGE_WIN_RET(alpha,N) \

IPP_BADARG_RET(fabs(alpha)*(N-1)/2 > IPP_MAX_EXP64f, ippStsHugeWinErr)

#define IPP_HUGE_WIN2_RET(alpha,N) \

IPP_BADARG_RET(fabs(alpha)*(N-1)/2 > IPP_MAX_EXP32f, ippStsHugeWinErr)

Take a look at the Kaiser window formula and you'll uderstand the reason of such limitation. If you really need so huge alphas - use 64f flavor of this function

Regards,

Igor

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Could you explain why that limitation is in place?

Is it because of the maximum precision?

I need a Kaiser window like the attached png for 1024 points.

In python, this would be numpy.kaiser of len 1024 and alpha coefficient of 6.3.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

Sorry, I meant beta of 6.3, since that's what's used in numpy. Alpha would be around 2.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

It would be helpful ifthis restriction could be added to the Ref manual.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page