def _parse_sam_region(region):
    """ Splits and casts SAM-formatted regions"""
    sam_region = ':'.join(region.split()).replace('-', ':').split(':')
    for i, arg in enumerate(sam_region[1:]):
        sam_region[i + 1] = int(arg)
    return sam_region
