def METHOD_NAME(grayscale, num_channels):
    # pre-process for imread. check arguments.
    if num_channels not in [-1, 0, 1, 3, 4]:
        raise ValueError("Currently num_channels supports [-1, 0, 1, 3, 4].")
    if not grayscale and num_channels in [0, 1]:
        raise ValueError("If grayscale=False, num_channels must be [-1, 3, 4]."
                         "If you want to get image as gray-scale, try grayscale=True ")