towhee.utils.ndarray_utils.rgb2bgr

towhee.utils.ndarray_utils.rgb2bgr(img: Union[ndarray, Image]) ndarray[source]

Convert an RGB image into ndarray of mode BGR.

Parameters:

img (Union[np.ndarray, ‘towhee.types.Image’]) – An RGB image either in the form of ndarray or towhee’s Image.

Returns:

(np.ndarray)

An ndarray in the mode of BGR.