Table of Contents |
---|
How is the ERA-interim daily data organised in MARS?
Info |
---|
In general it is organised, as a huge tree, with the indentation below, showing different levels down that tree:
|
What would be the natural way to group requests?
Info |
---|
The idea is to request as much data as possible from the same tape file . The natural way to group requests would be: Note: 'all' means 'all' that the user wants. It doesn't have to be all parameters. |
Web-API examples
...
UERRA SMHI pressure level request
Info |
---|
You can use the variable 'target' to organise the requested data in separate files if you wish. |
Code Block | ||
---|---|---|
| ||
#!/usr/bin/env python import calendar from ecmwfapi import ECMWFDataServer server = ECMWFDataServer() def retrieve_interimuerra_eswi(): """ A function to demonstrate how to iterate efficiently over several years and months etc for a particular UERRA interim_request. request for origin SMHI. Change the variables below to adapt the iteration to your needs. You can use the variable 'target' to organise the requested data in files as you wish. In the example below the data are organised in files per month. (eg "interimuerra_eswi_daily_201510.grb") """ yearStart = 20142008 yearEnd = 20152009 monthStart = 1 monthEnd = 12 for year in list(range(yearStart, yearEnd + 1)): for month in list(range(monthStart, monthEnd + 1)): startDate = '%04d%02d%02d' % (year, month, 1) numberOfDays = calendar.monthrange(year, month)[1] lastDate = '%04d%02d%02d' % (year, month, numberOfDays) target = "interimuerra_eswi_daily_%04d%02d.grb" % (year, month) requestDates = (startDate + "/TO/" + lastDate) interimuerra_eswi_request(requestDates, target) def interimuerra_eswi_request(requestDates, target): """ A UERRA Anrequest ERAfor interimorigin requestSMHI, for analysis pressure level data. Change the keywords below to adapt it to your needs. (eg to add or to remove levels, parameters, times etc) Request cost per day is 112XXXX fields, 14.2326XXXX Mbytes """ server.retrieve({ "class": "eiur", "stream": "oper", "type": "an", "dataset": "interim"uerra", "origin" : "eswi", "date": requestDates, "expver": "1prod", "levtype": "pl", "levelist": "100/500/700/750/850/925/1000", "param": "129.128/133.128/157130.128/248.128", "target": target, "time": "00/06/12/18", "grid": "0.75/0.75" }) if __name__ == '__main__': retrieve_interimuerra_eswi() |
Useful links
...
|
...