from pyaerocom.plot import plotmaps
from GLOB import OUT_DIR_MAPS  # import standard output directory

if __name__ == '__main__':

    import argparse
    default_model = "AATSR_SU_v4.3"

    parser = argparse.ArgumentParser(
        description='command line interface to the readgrid class')
    parser.add_argument("model",
                        help="model to read",
                        nargs="?",
                        const=default_model,
                        default=default_model,
                        type=str)

    args = parser.parse_args()
    if args.model:
        model = args.model

    var = "od550aer"

    # Create data import object
    test = ReadGridded(model, '2010-01-01', '2011-12-31', verbose=True)

    print(test.vars)

    data = test.read_var("od550aer", ts_type="daily")

    #plotmaps(data, VerboseFlag=True, plotdir=OUT_DIR_MAPS)
Exemplo n.º 2
0
from pyaerocom.io.readgridded import ReadGridded
gridded_reader = ReadGridded(data_id="EMEP_rv4.1.1.T2.1_ctl")
data = gridded_reader.read_var(var_name='wetso4', ts_type="daily")

print(data.unit)

data.unit = 'mg/m2'

print(data.unit)
Exemplo n.º 3
0
def test_ReadGridded_prefer_longer(options, expected):
    r = ReadGridded(data_dir=path_tm5)
    gridded = r.read_var('abs550aer', **options)
    assert gridded.ts_type == expected