Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.

OpenVX, can't get correct matrix rows.

Xiaoying__Y
Beginner
472 Views

Hi,  there

I am trying to pass a vx_matrix to opencl kernel and I get the following error.

[ ERROR ] OpenVX error callback: vxQueryMatrix failed: can't get matrix rows

I am pretty new to openvx ,would you please kindly tell me what could I have done wrong about the implement?

And if possible, please tell me How I can get the more detailed log of the error?

///////////////////////////////////
//Host:
///////////////////////////////////
vx_matrix colormatrix= vxCreateMatrix(ovxContext,VX_TYPE_UINT8,256,3); 
CHECK_VX_OBJ(colormatrix);
vx_uint8 colormatrix_lut[3][256]=
{
{0,1,2...to 255},
{0,1,2...to 255},
{0,1,2...to 255},
};

//writing the lut above to the vx_matrix object
CHECK_VX_STATUS(vxCopyMatrix(colormatrix_lut,(void*)stColorMatrixReg_Lut,VX_WRITE_ONLY,VX_MEMORY_TYPE_HOST));



///////////////////////////////////
//validator supposed the matrix above is in paramter[6]
///////////////////////////////////
...
        vx_uint32 para_06_matrix_col=0;
        vx_uint32 para_06_matrix_row=0;
        vx_enum para_06_matrix_type;
        if(vxQueryMatrix((vx_matrix)parameters[6],VX_MATRIX_TYPE,&para_06_matrix_type, sizeof(para_06_matrix_type)) == VX_SUCCESS&&
           (vxQueryMatrix((vx_matrix)parameters[6],VX_MATRIX_ROWS,&para_06_matrix_row, sizeof(para_06_matrix_row))==VX_SUCCESS)&&
           (vxQueryMatrix((vx_matrix)parameters[6],VX_MATRIX_COLUMNS,&para_06_matrix_col, sizeof(para_06_matrix_col))==VX_SUCCESS))
        {
                if(para_06_matrix_type==VX_TYPE_UINT8&&para_06_matrix_row==3&&para_06_matrix_col==256)
                {
                        status=VX_SUCCESS;
                }
                else
                {
                        status = VX_ERROR_INVALID_VALUE;
                        vxAddLogEntry((vx_reference)node, status, "input colormatrixcol and row incorrect\n ");
                }
        }

///////////////////////////////////
/////////////////////////////////////kernel in opencl
///////////////////////////////////
kernel kernel_name(...

	global uchar* stThreeDimensionReg_Lut_matrix_0, // pointer to matrix items
	uint32 rows_stThreeDimensionReg_Lut_matrix_0, // number of rows
	uint32 cols_stThreeDimensionReg_Lut_matrix_0, // number of columns
...
)
{
}

Thank you in advance for you help.

Xiaoying

0 Kudos
2 Replies
Shubha_R_Intel
Employee
472 Views

Dear Xiaoying, Y,

Since this is the OpenVino forum where questions related to Model Optimizer and Inference Engine are answered, please direct your OpenVX posts to the below forum:

https://community.khronos.org/c/openvx

Thanks !

Shubha

 

0 Kudos
Xiaoying__Y
Beginner
472 Views

Hi Shubha

Thank you for the reply.

Actually I am afraid this extension is from intel as described in the link below.

https://software.intel.com/en-us/openvino-ovx-guide-intels-extensions-to-the-openvx-api-opencl-custom-kernels

That's why I post this question here.

Anyway,  I will try my luck in khronos forum too.

Thanks for the information.

Regards,

Xiaoying

Shubha R. (Intel) wrote:

Dear Xiaoying, Y,

Since this is the OpenVino forum where questions related to Model Optimizer and Inference Engine are answered, please direct your OpenVX posts to the below forum:

https://community.khronos.org/c/openvx

Thanks !

Shubha

 

0 Kudos
Reply