예제 #1
0
def decode(data_buffer):
    """
    Decode grey-scale image via JPEG-LS using CharLS implementation.
    """

    data_image = _CharLS.decode(data_buffer)

    return data_image
예제 #2
0
def decode(data_buffer):
    """
    Decode grey-scale image via JPEG-LS using CharLS implementation.
    """

    data_image = _CharLS.decode(data_buffer)

    return data_image
예제 #3
0
def read(fname):
    """
    Read image data from JPEG-LS file.
    """
    with open(fname, "rb") as fo:
        string_buffer = fo.read()

    data_buffer = np.fromstring(string_buffer, dtype=np.uint8)

    data_image = _CharLS.decode(data_buffer)

    # Done.
    return data_image
예제 #4
0
def read(fname):
    """
    Read image data from JPEG-LS file.
    """
    with open(fname, 'rb') as fo:
        string_buffer = fo.read()

    data_buffer = np.fromstring(string_buffer, dtype=np.uint8)

    data_image = _CharLS.decode(data_buffer)

    # Done.
    return data_image