def electrons2adu(electrons, ccd_gain):
    """
    converts electron counts into analog-to-digital unit

    :param electrons:
    :return: adu value corresponding to electron count
    """
    return electrons / ccd_gain