- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I want to use VME advanced version to do video analysis. some of the information may be useful, like mv, intra mode etc. But in my program, intra mode seems not correct. MVs is OK. Every MBs has a stranger value(negative value or large value) which is not a correct intra prediction mode.
struct search_predictor_modes |
{ |
char luma_16x16_block; |
char luma_8x8_block[4]; |
char luma_4x4_block[16]; |
char chroma_8x8_block; |
}; |
cl_mem memIntra = clCreateBuffer(...CL_MEM_ALLOC_HOST_PTR...,sizoef(search_predictor_modes)*numMBs);
search_predictor_modes cIntraModes = new search_predictor_modes [numMBs];
and set the 11th argumant to obtain intra modes
When kernel finished running, use clEnqueueReadBuffer or MapBuffer to get the results into cIntraModes .
I think these procedure are correct, because MVs results is OK. but the intra result is actually not seems like INTRA MODE (0x0-0x8).
My PC platform is i5-6500 with HD 530 graphics.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Intra prediction is supported, but it is off by default -- including in the sample. The sample includes two flags you can set to enable intra prediction:
#define CL_ME_CHROMA_INTRA_PREDICT_ENABLED_INTEL 0x1 #define CL_ME_LUMA_INTRA_PREDICT_ENABLED_INTEL 0x2
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Intra prediction is supported, but it is off by default -- including in the sample. The sample includes two flags you can set to enable intra prediction:
#define CL_ME_CHROMA_INTRA_PREDICT_ENABLED_INTEL 0x1 #define CL_ME_LUMA_INTRA_PREDICT_ENABLED_INTEL 0x2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Great! I forgot to set these two arguments. still use default value 0 according to the page link https://software.intel.com/en-us/articles/intro-to-advanced-motion-estimation-extension-for-opencl, which write as flags
defines any optional modes or behaviors when computing motion estimation, skip-check and/or intra-prediction algorithms. Currently the only supported value is 0, however, the following token is reserved for future support.
Okay, thanks a lot. It can work well. By the way, the first video frame should be treat as intra picture, no reference image. How can I set the ref_image argument for this case?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Jeffrey, I met a strange problem. Details are as follows
I use VME to obtain MVs information. mv output memory is allocate as CL_MEM_ALLOC_HOST_PTR, when kernel finished,
Scheme1: I use MapBuffer API, and then excute memcpy function to Host application memory, and then do some CPU operators, at last excute UmMap. We assume this scheme time consume is 100ms. MVs is correct.
Scheme2: However when I skip step of excute memcpy function to Host application memory. Just use mapped pointer to do some CPU operators. and then UnMap. this scheme time is more fast. Probably 70ms. MVs is correct and same as Scheme1.
But today I re-run the kernel and found the Scheme2 no time gain. obviously greater than 70ms. It is so strange and I am very depressed. Whether the VME kernel execution time is not stable?or GPU has some problems.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page