(self, image)
return humans
Detect human skeleton from image.
        Arguments:
            image: RGB image with arbitrary size. It will be resized to (self._w, self._h).
        Returns:
            humans {list of class Human}: 
                `class Human` is defined in 
                "src/githubs/tf-pose-estimation/tf_pose/estimator.py"
                
                The variable `humans` is returned by the function
                `TfPoseEstimator.inference` which is defined in
                `src/githubs/tf-pose-estimation/tf_pose/estimator.py`.

                I've written a function `self.humans_to_skels_list` to 
                extract the skeleton from this `class Human`.
Detect human skeleton from image.
        Arguments:
            image: RGB image with arbitrary size. It will be resized to (self._w, self._h).
        Returns:
            humans {list of class Human}: 
                `class Human` is defined in 
                "src/githubs/tf-pose-estimation/tf_pose/estimator.py"
                
                The variable `humans` is returned by the function
                `TfPoseEstimator.inference` which is defined in
                `src/githubs/tf-pose-estimation/tf_pose/estimator.py`.
Detect human skeleton from image . Arguments : image : RGB image with arbitrary size . It will be resized to ( self . _w self . _h ) . Returns : humans { list of class Human } : class Human is defined in src / githubs / tf - pose - estimation / tf_pose / estimator . py The variable humans is returned by the function TfPoseEstimator . inference which is defined in src / githubs / tf - pose - estimation / tf_pose / estimator . py .
def detect(self, image):
        ''' Detect human skeleton from image.
        Arguments:
            image: RGB image with arbitrary size. It will be resized to (self._w, self._h).
        Returns:
            humans {list of class Human}: 
                `class Human` is defined in 
                "src/githubs/tf-pose-estimation/tf_pose/estimator.py"
                
                The variable `humans` is returned by the function
                `TfPoseEstimator.inference` which is defined in
                `src/githubs/tf-pose-estimation/tf_pose/estimator.py`.

                I've written a function `self.humans_to_skels_list` to 
                extract the skeleton from this `class Human`. 
        '''

        self._cnt_image += 1
        if self._cnt_image == 1:
            self._image_h = image.shape[0]
            self._image_w = image.shape[1]
            self._scale_h = 1.0 * self._image_h / self._image_w
        t = time.time()

        # Do inference
        humans = self._tf_pose_estimator.inference(
            image, resize_to_default=(self._w > 0 and self._h > 0),
            upsample_size=self._resize_out_ratio)

        # Print result and time cost
        elapsed = time.time() - t
        self._logger.info('inference image in %.4f seconds.' % (elapsed))

        return humans
def detect ( self , image ) : self . _cnt_image += 1 if self . _cnt_image == 1 : self . _image_h = image . shape [ 0 ] self . _image_w = image . shape [ 1 ] self . _scale_h = 1.0 * self . _image_h / self . _image_w t = time . time ( ) # Do inference humans = self . _tf_pose_estimator . inference ( image , resize_to_default = ( self . _w > 0 and self . _h > 0 ) , upsample_size = self . _resize_out_ratio ) # Print result and time cost elapsed = time . time ( ) - t self . _logger . info ( 'inference image in %.4f seconds.' % ( elapsed ) ) return humans