pycasso-meteo-tm5-convert-hdf-to-nc.rc 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464
  1. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  2. !
  3. ! Include this file in the rcfile:
  4. !
  5. ! #include /path/to/thisfile.rc
  6. !
  7. ! The following variables are used and should have been defined:
  8. !
  9. ! * in the main rcfile:
  10. !
  11. ! ! short names for regions:
  12. ! my.region1 : glb600x400
  13. ! my.region2 : eur300x200
  14. ! my.region3 : eur100x100
  15. !
  16. ! ! grid names for meteo input:
  17. ! my.region1m : ${my.region1}
  18. ! my.region2m : ${my.region2}
  19. ! my.region3m : eux100x100
  20. !
  21. ! ! meteo class (and level key?) for ecmwf data:
  22. ! my.ecclass_ecl : od_${ECL}
  23. ! !my.ecclass_ecl : ei
  24. !
  25. ! ! call meteo setup script (T|F) ?
  26. ! my.tmm.setup.apply : F
  27. !
  28. ! * in the machine rc file:
  29. !
  30. ! ! local directory with unpacked meteo files:
  31. ! my.meteo.dir : /scratch/shared/meteo
  32. !
  33. ! ! where to search of missing files ?
  34. ! my.meteo.search : ec:ecfs[nlh]:TM/meteo
  35. !
  36. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  37. !
  38. ! The keys that define meteo usage have the form:
  39. !
  40. ! <key(s)>.<name(s)>
  41. !
  42. ! or, if the property depends on the zoom region:
  43. !
  44. ! <key(s)>.<region_name>.<name(s)>
  45. !
  46. ! The region_name is either a '*' or names like 'glb300x200' etc.
  47. !
  48. ! Multipe names could apply to the same field; see the table below.
  49. ! A '*' applies to all fields.
  50. ! If more than name applies to a field, the last one defines the value.
  51. ! For example, the following 3 keys all apply to the 'oro' field,
  52. ! but the resulting temporal interpolation will be 'const' :
  53. !
  54. ! meteo.tinterp.* : interp3
  55. ! meteo.tinterp.sfc.an : interp6
  56. ! meteo.tinterp.oro : const
  57. !
  58. ! Summary of possible name(s) :
  59. !
  60. ! field name(s) that apply to this field
  61. ! -------- ------------------------------------------------------
  62. ! sp ml sp
  63. ! mfw ml mflux_w
  64. ! tsp ml mflux_w
  65. ! mfu ml mflux_uv
  66. ! mfv ml mflux_uv
  67. ! T ml temper
  68. ! Q ml humid
  69. ! CLWC ml cloud
  70. ! CIWC ml cloud
  71. ! CC ml cloud
  72. ! CCO ml cloud
  73. ! CCU ml cloud
  74. ! eu ml convec
  75. ! ed ml convec
  76. ! du ml convec
  77. ! dd ml convec
  78. ! oro sfc sfc.const sfc.an oro
  79. ! lsm sfc sfc.const sfc.an lsm
  80. ! ci sfc sfc.inst sfc.day sfc.fc ci
  81. ! sst sfc sfc.inst sfc.fc sst
  82. ! u10m sfc sfc.inst sfc.fc u10m
  83. ! v10m sfc sfc.inst sfc.fc u10m
  84. ! g10m sfc sfc.inst sfc.fc g10m
  85. ! src sfc sfc.inst sfc.fc src
  86. ! d2m sfc sfc.inst sfc.fc d2m
  87. ! t2m sfc sfc.inst sfc.fc t2m
  88. ! skt sfc sfc.inst sfc.fc blh
  89. ! blh sfc sfc.inst sfc.fc skt
  90. ! sshf sfc sfc.aver sfc.fc sshf
  91. ! slhf sfc sfc.aver sfc.fc slhf
  92. ! ewss sfc sfc.aver sfc.fc ewss
  93. ! nsss sfc sfc.aver sfc.fc nsss
  94. ! cp sfc sfc.aver sfc.fc cp
  95. ! lsp sfc sfc.aver sfc.fc lsp
  96. ! sf sfc sfc.aver sfc.fc sf
  97. ! ssr sfc sfc.aver sfc.fc ssr
  98. ! sd sfc sfc.inst sfc.day sfc.fc sd
  99. ! swvl1 sfc sfc.inst sfc.day sfc.fc swvl1
  100. ! tv sfc sfc.inst sfc.day sfc.an veg
  101. ! cvl sfc sfc.inst sfc.day sfc.an veg
  102. ! cvh sfc sfc.inst sfc.day sfc.an veg
  103. ! albedo sfc sfc.inst sfc.day sfc.an albedo
  104. ! sr sfc sfc.inst sfc.day sfc.an sr
  105. ! srols sfc sfc.inst sfc.day sfc.an srols
  106. !
  107. ! Background:
  108. ! o 'ml' and 'sfc' indicate model levels and surface level
  109. ! o surface fields could have a constant value (sfc.const),
  110. ! have instananeous values (sfc.inst),
  111. ! or averaged over an accumulation interval (sfc.aver).
  112. ! o when meteo was produced by TMPP, some fields were stored
  113. ! as daily averages (sfc.day)
  114. ! o surface fields could originate from an ecmwf forecast (sfc.fc)
  115. ! or from the analysis (sfc.an)
  116. ! o group names apply to fields that usually belong together,
  117. ! for example the vegation fields (veg)
  118. !
  119. !====================================================
  120. ! ~ get number of meteo levels, and set class variable for filenames
  121. !====================================================
  122. #if "${my.meteo.class}" == "od" :
  123. ! ~ number of levels for od data increases in time ...
  124. #if int("${timerange.start}"[0:4]) <= 2005 :
  125. my.meteo.nlev : 60
  126. #else
  127. my.meteo.nlev : 91
  128. #endif
  129. my.ecclass_ecl : ${my.meteo.class}_L${my.meteo.nlev}
  130. #elif "${my.meteo.class}" == "ei" :
  131. ! ~ era interim
  132. my.meteo.nlev : 60
  133. my.ecclass_ecl : ${my.meteo.class}
  134. #else :
  135. #error "unsupported meteo class : ${my.meteo.class}"
  136. #endif
  137. !previously ECLEVS:
  138. my.eclevs : ml${my.meteo.nlev}
  139. !------------------------------
  140. ! name for choice of number of model levels (previously LEVS)
  141. !------------------------------
  142. #if "${my.levs}" in ["all",""] :
  143. my.mlevs : ml${my.meteo.nlev}
  144. #elif "${my.levs}" in ["tropo25","tropo34","ml40"] :
  145. my.mlevs : ${my.levs}
  146. #else :
  147. #error "unsupported number of model levels : ${my.levels}"
  148. #endif
  149. !------------------------------
  150. ! ** global surface region:
  151. !------------------------------
  152. ! name of global surface region in meteo files:
  153. #if "${region.glbsfc}" != ""
  154. my.regiongm : ${region.glbsfc}
  155. #else
  156. my.regiongm : glb100x100
  157. #endif
  158. !------------------------------
  159. ! ** which fields should be read ?
  160. !------------------------------
  161. ! by default, load nothing:
  162. meteo.read.*.* : F
  163. ! ~ read model level fields,
  164. ! except on global surface region:
  165. meteo.read.*.ml : T
  166. meteo.read.${my.regiongm}.ml : F
  167. ! ~ read surface fields on global surface region:
  168. meteo.read.${my.regiongm}.sfc : T
  169. ! not the exotic ones yet ...
  170. meteo.read.${my.regiongm}.ch4fire : F
  171. !------------------------------
  172. ! ** temporal interpolation
  173. !------------------------------
  174. !
  175. ! Temporal interpolation is defined first by general key:
  176. !
  177. ! meteo.tinterp.* : const6
  178. !
  179. ! Optionally, different settings might be chosen for specific meteo:
  180. !
  181. ! sp mflux_uv mflux_w temper humid cloud convec surf.inst surf.aver surf.day albedo sr
  182. !
  183. ! Possible time interpolations:
  184. ! o month : constant in month
  185. ! o const : constant
  186. ! o const24 : constant in 24hr intervals [00:00,24:00]
  187. ! o const6 : constant in 6hr intervals [21:00,03:00] [03:00,09:00] ...
  188. ! o const3 : constant in 3hr intervals [22:30,01:30] [01:30,04:30] ...
  189. ! o interp6 : interpoloated between 00, 06, 12, 18
  190. ! o interp6_3 : interpoloated between 03, 09, 15, 21
  191. ! o interp3 : interpoloated between 00, 03, 06, 09, 12, 15, 18, 21
  192. ! o aver6 : time averages over intervals ]00,06], [06,12], ...
  193. ! o aver3 : time averages over intervals [00,03], [03,06], ...
  194. ! o aver24 : time averages over interval [00,24]
  195. ! o aver24_3 : time averages over interval [21,21]
  196. !
  197. !
  198. ! ~~~ od meteo production
  199. !
  200. ! ~ fc fields are 3 hourly instantaneous; keep them constant,
  201. ! except for the accumulated fields which have been averaged over 3 hour:
  202. ! ~ fc 3 hourly
  203. meteo.tinterp.* : const3
  204. meteo.tinterp.sp : interp3
  205. meteo.tinterp.sfc.aver : aver3
  206. ! ~ an fields 6 hourly instantaneous; keep them constant,
  207. ! except oro and lsm which are constant:
  208. meteo.tinterp.sfc.an : interp6
  209. ! ~ constant
  210. meteo.tinterp.oro : const
  211. meteo.tinterp.lsm : const
  212. ! ~ surface roughness Olsson/Ganzeveld is per month:
  213. meteo.tinterp.srols : month
  214. !------------------------------
  215. ! ** source keys : how to form a file name ?
  216. !------------------------------
  217. !
  218. ! TMM requires keys on how to form a meteo filename.
  219. ! A key should be defined for each region (names are in 'dims_grid.F90'):
  220. !
  221. ! tmm.sourcekey.${my.region1}.* : tmpp:class=od;type=fc;levs=ml60;grid=glb3x2;tres=_21p06
  222. !
  223. ! Optionally, some specific fields might be read from a different set:
  224. !
  225. ! tmm.sourcekey.${my.region1}.sp : ecmwf:form=3hr;class=od;type=fc;nlev=60;sh=159;tres=_fc012up2tr3
  226. !
  227. ! Possible specific fields:
  228. !
  229. ! sp mflux_uv mflux_w temper humid cloud convec
  230. ! surf oro lsm albedo sr
  231. !
  232. ! Examples of source keys:
  233. !
  234. ! * tmpp:class=od;type=fc;levs=ml60;grid=glb3x2;tres=_21p06
  235. !
  236. ! Identifies the regular TMPP hdf files:
  237. ! xxxx/od-fc-2000-01-ml60-glb3x2-uvsp_20000101_21p06.hdf
  238. ! etc
  239. !
  240. ! * tmpp:class=od;type=fc;levs=ml60;grid=glb3x2;tres=_21p06;pathsep=\;namesep=\
  241. !
  242. ! Idem, but then for full Windows path names:
  243. ! xxxx\od\fc\2000\01\ml60\glb3x2\uvsp_20000101_21p06.hdf
  244. ! etc
  245. !
  246. ! * tm5:mdir=ec-fc012up2-ml60_tropo25-glb6x4;tres=_00p06
  247. !
  248. ! * msc-data:nlev=71;sh=47;mdir=cmam;type=iau;tres=_6hrly;sp_unit=hPa
  249. !
  250. ! * ncep-gfs:
  251. ! * ncep-cdc:
  252. !
  253. ! Coarsened to zoom regions and combined layers:
  254. tmm.sourcekey.${my.region1}.ml : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region1m};tres=_00p03
  255. #if len("${my.region2m}") > 0 :
  256. tmm.sourcekey.${my.region2}.ml : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region2m};tres=_00p03
  257. #endif
  258. #if len("${my.region3m}") > 0 :
  259. tmm.sourcekey.${my.region3}.ml : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region3m};tres=_00p03
  260. #endif
  261. #if len("${my.region4m}") > 0 :
  262. tmm.sourcekey.${my.region4}.ml : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region4m};tres=_00p03
  263. #endif
  264. #if len("${my.region5m}") > 0 :
  265. tmm.sourcekey.${my.region5}.ml : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region5m};tres=_00p03
  266. #endif
  267. tmm.sourcekey.*.sfc.fc : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-sfc-${my.regiongm};tres=_00p03
  268. tmm.sourcekey.*.sfc.an : tm5-hdf:mdir=ec-${my.ecclass_ecl}-an0tr6-sfc-${my.regiongm};tres=_00p06
  269. !------------------------------
  270. ! ** install meteo files
  271. !------------------------------
  272. ! location of meteo files;
  273. ! either a permanent archive, or a temporary scratch:
  274. tmm.dir : ${my.meteo.dir}
  275. ! Clean up the temporary meteo ?
  276. ! o Set the clean flag (T|F) such that files that have not been accessed
  277. ! for a long time are removed if a maximum buffer usage is exceeded.
  278. ! o specify a maximum size: 500k, 1M, 2G
  279. !
  280. tmm.dir.clean : T
  281. tmm.dir.size : 30G
  282. !
  283. ! Meteo files could be setup before the actual program is started.
  284. ! First set the main switch to apply this or not.
  285. ! If to be applied, specify details for a number of sets;
  286. ! each set can be applied by a seperate flag.
  287. !
  288. tmm.setup.apply : ${my.tmm.setup.apply}
  289. ! display progress ?
  290. tmm.setup.verbose : T
  291. ! file permission mode for newly created files:
  292. ! o user archive : 644
  293. ! o archive shared by group : 664
  294. tmm.setup.mode : 664
  295. ! number of sets defined below:
  296. tmm.setup.nset : 7
  297. tmm.setup.001.apply : T
  298. tmm.setup.001.files : oro lsm albedo sr srols veg
  299. tmm.setup.001.sources : tm5-hdf:mdir=ec-${my.ecclass_ecl}-an0tr6-sfc-${my.regiongm};tres=_00p06
  300. tmm.setup.001.search : ${my.meteo.search}
  301. !
  302. tmm.setup.002.apply : T
  303. tmm.setup.002.files : blh ci cp d2m ewss g10m lsp nsss sd sf skt slhf src sshf ssr ssrd sst str strd swvl1 t2m u10m v10m
  304. tmm.setup.002.sources : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-sfc-${my.regiongm};tres=_00p03
  305. tmm.setup.002.search : ${my.meteo.search}
  306. !
  307. tmm.setup.003.apply : T
  308. tmm.setup.003.files : sp mfuv mfw t q cld sub
  309. tmm.setup.003.sources : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region1m};tres=_00p03
  310. tmm.setup.003.search : ${my.meteo.search}
  311. !
  312. #if len("${my.region2m}") > 0 :
  313. tmm.setup.004.apply : T
  314. tmm.setup.004.files : sp mfuv mfw t q cld sub
  315. tmm.setup.004.sources : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region2m};tres=_00p03
  316. tmm.setup.004.search : ${my.meteo.search}
  317. #else :
  318. tmm.setup.004.apply : F
  319. #endif
  320. !
  321. #if len("${my.region3m}") > 0 :
  322. tmm.setup.005.apply : T
  323. tmm.setup.005.files : sp mfuv mfw t q cld sub
  324. tmm.setup.005.sources : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region3m};tres=_00p03
  325. tmm.setup.005.search : ${my.meteo.search}
  326. #else :
  327. tmm.setup.005.apply : F
  328. #endif
  329. !
  330. #if len("${my.region4m}") > 0 :
  331. tmm.setup.006.apply : T
  332. tmm.setup.006.files : sp mfuv mfw t q cld sub
  333. tmm.setup.006.sources : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region4m};tres=_00p03
  334. tmm.setup.006.search : ${my.meteo.search}
  335. #else :
  336. tmm.setup.006.apply : F
  337. #endif
  338. !
  339. #if len("${my.region5m}") > 0 :
  340. tmm.setup.007.apply : T
  341. tmm.setup.007.files : sp mfuv mfw t q cld sub
  342. tmm.setup.007.sources : tm5-hdf:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region5m};tres=_00p03
  343. tmm.setup.007.search : ${my.meteo.search}
  344. #else :
  345. tmm.setup.007.apply : F
  346. #endif
  347. !------------------------------
  348. ! ** output meteo
  349. !------------------------------
  350. ! should meteo be put out ? (used in the storage script):
  351. tmm.output : T
  352. ! By default, write none:
  353. tmm.output.*.* : F
  354. ! ~ model level fields:
  355. tmm.output.*.ml : T
  356. ! ~ surface fields on global surface region:
  357. tmm.output.${my.regiongm}.sfc : T
  358. ! Define output format and/or first part of file name:
  359. !
  360. ! tmm.destkey.${my.region1}.* : tm5:mdir=ec-fc012up2-tropo25-glb6x4;tres=_00p06
  361. !
  362. ! Optionally overwrite for special sets
  363. !
  364. ! sp mflux_w mflux_uv temper humid cloud convec albedo sr
  365. !
  366. ! ** od/ei production
  367. !
  368. tmm.destkey.${my.region1}.ml : tm5-nc:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region1}-<yyyy>;tres=_00p03
  369. #if "${my.region2}" != "" :
  370. tmm.destkey.${my.region2}.ml : tm5-nc:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region2}-<yyyy>;tres=_00p03
  371. #endif
  372. #if "${my.region3}" != "" :
  373. tmm.destkey.${my.region3}.ml : tm5-nc:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region3}-<yyyy>;tres=_00p03
  374. #endif
  375. #if "${my.region4}" != "" :
  376. tmm.destkey.${my.region4}.ml : tm5-nc:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region4}-<yyyy>;tres=_00p03
  377. #endif
  378. #if "${my.region5}" != "" :
  379. tmm.destkey.${my.region5}.ml : tm5-nc:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-${my.mlevs}-${my.region5}-<yyyy>;tres=_00p03
  380. #endif
  381. !
  382. tmm.destkey.${my.regiongm}.sfc : tm5-nc:mdir=ec-${my.ecclass_ecl}-fc012up2tr3-sfc-${my.regiongm}-<yyyy>;tres=_00p03
  383. tmm.destkey.${my.regiongm}.sfc.an : tm5-nc:mdir=ec-${my.ecclass_ecl}-an0tr6-sfc-${my.regiongm}-<yyyy>;tres=_00p06
  384. ! TM5 writes new meteo files to:
  385. tmm.output.dir : ${my.project.dir}/tm5_meteo_out
  386. ! ensure creation via 'install' facilty:
  387. tmm.output.install.dir : ${tmm.output.dir}
  388. !------------------------------
  389. ! Options for "tm5-tmm-store" script.
  390. !------------------------------
  391. ! display messages ?
  392. tmm.output.store.verbose : T
  393. ! Specify one or more archives.
  394. ! Files are stored in monthly tar files if an archive ends with '/*.tar';
  395. ! large 3D files per 10 or 5 days for '/*.tar10' or '/*.tar5' .
  396. ! Examples:
  397. ! ${SCRATCH}/TM/meteo_day
  398. ! ecfs:/nlh/TM/meteo/*.tar
  399. ! mos:umask=002%/fa/ks/meteo/*.tar
  400. ! NOTE: files are removed from <tmm.output.dir> after storage ...
  401. !
  402. !tmm.output.store.archives : ecfs:umask=002%/nlh/TM/meteo-nc/*.tar5
  403. tmm.output.store.archives : ${SCRATCH}/NO-TAPE-YET/TM/meteo-nc/*.tar5
  404. ! zip tar files (empty or zipper command: gzip bzip2):
  405. tmm.output.store.zipper : gzip
  406. !------------------------------
  407. ! ** CF conventions
  408. !------------------------------
  409. ! file with standard name table;
  410. ! used for TM5 NetCDF meteo, comment if not used:
  411. !
  412. cf-standard-name-table : ${PWD}/tools/cf/data/cf-standard-name-table-v15.xml