def read_be_array(fmt, count, fp):
    arr = array.array(str(fmt))
    arr.fromstring(fp.read(count * arr.itemsize))
    return fix_byteorder(arr)
Reads an array from a file with big-endian data.
dataset/ETHPy150Open psd-tools/psd-tools/src/psd_tools/utils.py/read_be_array