Classes | Functions
node_scripts::deep_sort::deep_sort_tracker Namespace Reference

Classes

class  DeepSortTracker

Functions

def encoder
def extract_image_patch

Function Documentation

Definition at line 61 of file deep_sort_tracker.py.

def node_scripts.deep_sort.deep_sort_tracker.extract_image_patch (   image,
  bbox,
  patch_shape 
)
Extract image patch from bounding box.
copied from
https://github.com/nwojke/deep_sort/blob/master/tools/generate_detections.py

Parameters
----------
image : ndarray
    The full image.
bbox : array_like
    The bounding box in format (x, y, width, height).
patch_shape : Optional[array_like]
    This parameter can be used to enforce a desired patch shape
    (height, width). First, the `bbox` is adapted to the aspect ratio
    of the patch shape, then it is clipped at the image boundaries.
    If None, the shape is computed from :arg:`bbox`.

Returns
-------
ndarray | NoneType
    An image patch showing the :arg:`bbox`, optionally reshaped to
    :arg:`patch_shape`.
    Returns None if the bounding box is empty or fully outside of the image
    boundaries.

Definition at line 12 of file deep_sort_tracker.py.



jsk_perception
Author(s): Manabu Saito, Ryohei Ueda
autogenerated on Tue Jul 2 2019 19:41:08