def get_readout_time(dicom_img, dcm_info, dwell_time):
    """ Get read out time from a dicom image.

    Parameters
    ----------
    dicom_img: dicom.dataset.FileDataset object
        one of the dicom image loaded by pydicom.
    dcm_info: dict
        array containing dicom data.
    dwell_time: float
        Effective echo spacing in s.

    Returns
    -------
    readout_time: float
        read-out time in seconds.

    For philips scanner
    ~~~~~~~~~~~~~~~~~~~
    Formula to compute read out time:
    echo spacing (seconds) * (epi - 1) where
    epi = nb of phase encoding steps/ acceleration factor.

    For Siemens and GE scanners
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Readout time is written by dcm2niix in json summary dcm_info.
    """

    manufacturer = dcm_info["Manufacturer"]
    if manufacturer.upper() in ["SIEMENS", "GE MEDICAL SYSTEMS", "GE"]:
        readout_time = dcm_info["TotalReadoutTime"]

    elif manufacturer.upper() in ["PHILIPS MEDICAL SYSTEMS", "PHILIPS"]:
        acceleration_factor = dicom_img[int("2005", 16),
                                        int("140f", 16)][0][24, 36969].value
        etl = float(dicom_img[0x0018, 0x0089].value)
        readout_time = dwell_time * (etl - 1)
    else:
        raise ValueError("Unknown manufacturer : {0}".format(manufacturer))

    return readout_time