def to_sncosmo(light_curve):
    """Convert an lcdata light curve to sncosmo format.

    This adds the zp and zpsys keys that are required by sncosmo, and converts the band
    name to a string instead of the bytes type used internally.

    Parameters
    ----------
    light_curve : `~astropy.table.Table`
        Light curve in lcdata format

    Returns
    -------
    `~astropy.table.Table`
        Light curve in sncosmo format
    """
    light_curve = light_curve.copy()

    # Convert the band names from bytes to strings
    light_curve['band'] = light_curve['band'].astype(str)

    # Add in zeropoint information.
    light_curve['zp'] = 25.
    light_curve['zpsys'] = 'ab'

    return light_curve