imdecode
-
Description: Decode an image byte string to a NumPy image array.
-
Parameters
- byte_ (
bytes
): The image byte string to decode.
- byte_ (
-
Returns
- np.ndarray: The decoded image array.
-
Example
import docsaidkit as D
img = D.imread('lena.png')
encoded_bytes = D.imencode(img, IMGTYP=D.IMGTYP.PNG)
decoded_img = D.imdecode(encoded_bytes)