Public Member Functions | Public Attributes | List of all members
tools.drawing_tools.DrawingTools Class Reference
Inheritance diagram for tools.drawing_tools.DrawingTools:
Inheritance graph
[legend]

Public Member Functions

def __init__ (self, mode, opacity=0.6)
 
def draw_detection (self, image, boxes, scores, labels, detection_size, font=cv2.FONT_HERSHEY_SIMPLEX)
 
def get_cnn_metadata (self, mode)
 
def overlay_segmentation (self, image_to_overlay, segmentation)
 

Public Attributes

 metadata
 
 mode
 
 opacity
 

Detailed Description

Class for image processing

Definition at line 43 of file drawing_tools.py.

Constructor & Destructor Documentation

def tools.drawing_tools.DrawingTools.__init__ (   self,
  mode,
  opacity = 0.6 
)

Definition at line 46 of file drawing_tools.py.

Member Function Documentation

def tools.drawing_tools.DrawingTools.draw_detection (   self,
  image,
  boxes,
  scores,
  labels,
  detection_size,
  font = cv2.FONT_HERSHEY_SIMPLEX 
)
:param boxes, shape of  [num, 4]
:param scores, shape of [num, ]
:param labels, shape of [num, ]
:param image,
:param classes, the return list from the function `read_coco_names`

Definition at line 117 of file drawing_tools.py.

def tools.drawing_tools.DrawingTools.get_cnn_metadata (   self,
  mode 
)

Definition at line 51 of file drawing_tools.py.

def tools.drawing_tools.DrawingTools.overlay_segmentation (   self,
  image_to_overlay,
  segmentation 
)
Overlay an image with a segmentation result for multiple classes.

Parameters
----------
image_to_show : numpy.array
    An image of shape [width, height, 3]
segmentation : numpy.array
    Segmentation of shape [width, height]

Returns
-------
cv2.image
    The image overlayed with the segmentation

Definition at line 65 of file drawing_tools.py.

Member Data Documentation

tools.drawing_tools.DrawingTools.metadata

Definition at line 47 of file drawing_tools.py.

tools.drawing_tools.DrawingTools.mode

Definition at line 49 of file drawing_tools.py.

tools.drawing_tools.DrawingTools.opacity

Definition at line 48 of file drawing_tools.py.


The documentation for this class was generated from the following file:


cnn_bridge
Author(s): Noam C. Golombek , Alexander Beringolts
autogenerated on Mon Jun 10 2019 12:53:26