Hello, dear colleagiues!
I recently started studying computer vision. I'm very interested this direction. Now I'm studying the recognition of human poses, and I'm trying to remake some examples in C # to experiment further in Unity.
However, I can not find documentation or examples of how I could improve my code anywhere to find the poses of all people in the image. Could you tell me how I should change my code so that I can recognize the poses for all people in the image?
//314
CODE FRAGMENT:
private void RecognizePose( Mat image, Mat output_image,
List<Point> List<point> points, float[] data )
{
//315
//316 {
for( int i = 0; i < BODY_PARTS_MPI.Count; i++ ) {
//317
//318 output_image.get( i, 0, data );
//319
//320 Mat heat_map = new Mat ( 1, data.Length, CvType.CV_32FC1 );
//321
//322 heat_map.put( 0, 0, data );
//323
//324 //Originally, we try to find all the local maximums. To simplify a sample
//325 //we just find a global one. However only a single pose at the same time
//326 //could be detected this way.
//327 Core.MinMaxLocResult result = Core.minMaxLoc( heat_map );
//328
//329 heat_map.Dispose();
//330
//331 double x =
(
(image.cols() *
(result.maxLoc.x % matrix_output_columns)) /
matrix_output_columns;
//332
matrix_output_columns
);
double y =
(
(image.rows() *
(result.maxLoc.x / matrix_output_rows)) /
matrix_output_rows;
//333
//334
matrix_output_rows
);
if( result.maxVal > 0.1d ) points.Add( new Point( x, y ) );
//335 else points.Add( null );
//336 }
//337 }
}
Line #327 "Core.MinMaxLocResult result = Core.minMaxLoc( heat_map );" and next processing gets us only single person's pose.
pose. And comment for this line says the same. But how can I get the all local maximumns and detect all poses?
With best regards and best wishes,
Sergey Netyagin