arsenal.image

Module Contents

arsenal.image._default_sep_color = [100, 100, 100]
arsenal.image.Color
arsenal.image.resize_image(image: np.ndarray, *, height: Optional[int] = None, width: Optional[int] = None, resample=Image.NEAREST) → np.ndarray[source]

Resize image.

arsenal.image.vstack_with_sep(rows: List[np.ndarray], sep_width: int = 3, sep_color: Color = _default_sep_color, **kwargs) → np.ndarray[source]

Stack images on-top of one another with separator

arsenal.image.hstack_with_sep(cols: List[np.ndarray], sep_width: int = 3, sep_color: Color = _default_sep_color, **kwargs) → np.ndarray[source]

Stack images side-by-side with separator

arsenal.image.img_to_base64(img: Image.Image)str[source]

Encode image to base64 encoded JPEG

arsenal.image.base64_to_img(b64_img: str) → Image.Image[source]

Decode base64 encoded image.