- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am using ippiResize_32f_C1R to downscale images by a factor of 32. In order to use all original pixels, I tried using pixel supersampling (mode IPPI_INTER_SUPER). However, i notice that all pixes consequently have an offset of (amost?) exactly + 0.5!
I have tried different downscaling factors and images, but this offset remains. The offset is not present when using bicubic of bilinear downsampling.
Is this a known problem in IPP 3.0?
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Could somebody try to reproduce this problem? In my opion it is a fairly severe bug and although I can correct for it, I do not feel happy using subtraction as a workaround. Allthough I tested it for quite a lot of diffent cases (although not for higher versions of IPP), my software would break if suddenly the offset was gone or different.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, IPP v3.0 is about three years old. Could you please try your test on IPP v5.0? Note, you can download IPP v5.0 evaluation version for free.
BTW, it also would be useful if you provide some minimal info, what OS and on which CPU did you use? If you can attach simple test case it also can simplify us investigation.
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
IPP is used on many places (implemented my multiple people) in our software, so upgrading would require a lot of regression testing. This will happen eventually but not quite yet, i'm afraid (not my decision). However, Icould try if IPP v5.0 does not have this problem in a seperate project.
We are developing for dual Xeon processor Dell 670 machines running Windows 2000 SP 2.
This example program examplifies my problem
--------------------------------------------------------------------------
// supersamptest.cpp : Rescales image using supersampling
//
//
#include "stdafx.h"
#include
#include "ippi.h"
#include "ippcv.h"
#include
#include "ippi.h"
#include "ippcv.h"
int main(int argc, char* argv[])
{
int stepBytes;
const int Ipp32fSize = sizeof( Ipp32f );
int binsize = 2;
IppiSize srcSize = {100, 100};
IppiRect srcRoi = {0, 0, srcSize.width, srcSize.height };
Ipp32f* srcImage= ( Ipp32f * )ippiMalloc_32f_C1( srcSize.width, srcSize.height, &stepBytes );
IppiSize dstSize = {srcSize.width/binsize, srcSize.height/binsize};
Ipp32f* dstImage= ( Ipp32f * )ippiMalloc_32f_C1( dstSize.width, dstSize.height, &stepBytes );
{
int stepBytes;
const int Ipp32fSize = sizeof( Ipp32f );
int binsize = 2;
IppiSize srcSize = {100, 100};
IppiRect srcRoi = {0, 0, srcSize.width, srcSize.height };
Ipp32f* srcImage= ( Ipp32f * )ippiMalloc_32f_C1( srcSize.width, srcSize.height, &stepBytes );
IppiSize dstSize = {srcSize.width/binsize, srcSize.height/binsize};
Ipp32f* dstImage= ( Ipp32f * )ippiMalloc_32f_C1( dstSize.width, dstSize.height, &stepBytes );
// Set values in image to 1...
ippiSet_32f_C1R( 1.0f, srcImage, srcSize.width * Ipp32fSize, srcSize );
// Resize image...
ippiResize_32f_C1R( srcImage, srcSize, srcSize.width * Ipp32fSize, srcRoi, dstImage, dstSize.width * Ipp32fSize, dstSize, (1/(float)binsize), 1/((float)binsize), IPPI_INTER_SUPER );
// ...and read value 1.5 on any point!!!
printf("mean %f ",dstImage[dstSize.width*(dstSize.height/2)+(dstSize.width/2)]);
ippiFree( srcImage );
ippiFree( dstImage );
return 0;
}
--------------------------------------------------------------------------
ippiSet_32f_C1R( 1.0f, srcImage, srcSize.width * Ipp32fSize, srcSize );
// Resize image...
ippiResize_32f_C1R( srcImage, srcSize, srcSize.width * Ipp32fSize, srcRoi, dstImage, dstSize.width * Ipp32fSize, dstSize, (1/(float)binsize), 1/((float)binsize), IPPI_INTER_SUPER );
// ...and read value 1.5 on any point!!!
printf("mean %f ",dstImage[dstSize.width*(dstSize.height/2)+(dstSize.width/2)]);
ippiFree( srcImage );
ippiFree( dstImage );
return 0;
}
--------------------------------------------------------------------------
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
we donfirm that there is issue in ippiResample function. This bug will be fixed in future version of IPP. Please submit your bug report to Intel Premier Support to be automatically notified when fix will be available.
Thanks,
Vladimir
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page