esmvaltool/diag_scripts/validation.py
def apply_seasons(data_set_dict):
    """Extract seaons and apply a time mean per season"""
    data_file = data_set_dict['filename']
    logger.info("Loading %s for seasonal extraction", data_file)
    data_cube = iris.load_cube(data_file)
    seasons = ['DJF', 'MAM', 'JJA', 'SON']
    season_cubes = [extract_season(data_cube, season) for season in seasons]
    season_meaned_cubes = [
        season_cube.collapsed('time', iris.analysis.MEAN)
        for season_cube in season_cubes
    ]

    return season_meaned_cubes
Extract seaons and apply a time mean per season
Extract seaons and apply a time mean per season
Extract seaons and apply a time mean per season
def apply_seasons(data_set_dict):
    data_file = data_set_dict['filename']
    logger.info("Loading %s for seasonal extraction", data_file)
    data_cube = iris.load_cube(data_file)
    seasons = ['DJF', 'MAM', 'JJA', 'SON']
    season_cubes = [extract_season(data_cube, season) for season in seasons]
    season_meaned_cubes = [
        season_cube.collapsed('time', iris.analysis.MEAN)
        for season_cube in season_cubes
    ]
    return season_meaned_cubes
def apply_seasons ( data_set_dict ) : data_file = data_set_dict [ 'filename' ] logger . info ( "Loading %s for seasonal extraction" , data_file ) data_cube = iris . load_cube ( data_file ) seasons = [ 'DJF' , 'MAM' , 'JJA' , 'SON' ] season_cubes = [ extract_season ( data_cube , season ) for season in seasons ] season_meaned_cubes = [ season_cube . collapsed ( 'time' , iris . analysis . MEAN ) for season_cube in season_cubes ] return season_meaned_cubes
Extract seaons and apply a time mean per season
Extract seaons and apply a time mean per season
"""Extract seaons and apply a time mean per season"""
data_set_dict