diff --git a/input_data/MIMOC/meta.yaml b/input_data/MIMOC/meta.yaml new file mode 100644 index 0000000000000000000000000000000000000000..9f9ab9438f1bc9731bef9b0f743ef601a78b6e11 --- /dev/null +++ b/input_data/MIMOC/meta.yaml @@ -0,0 +1,33 @@ +repo_name: MIMOC + +people: Willi Rath () + +http_path_remote: https://git.geomar.de/data/MIMOC + +git_path_remote: git@git.geomar.de:data/MIMOC.git + +repo_description: | + A Monthly Isopycnal and Mixed-layer Ocean Climatology. + +prefixes: data doc + +data: + + - url: "https://www.pmel.noaa.gov/mimoc/" + cut_dirs: 2 + prefix: data + accept_files: "*.nc.gz,*.zip" + method: !!python/name:data_repo_renderer.WgetRecursive + +doc: + + - url: "https://www.pmel.noaa.gov/mimoc/index.html" + file_name: www.pmel.noaa.gov_mimoc_index.html + prefix: doc + method: !!python/name:data_repo_renderer.CurlSingleFile + +post_processing: + + - unzip -o -d data/ data/*.zip + - gunzip -f -v data/*.nc.gz + - util/convert_to_netCDF4_classic.sh diff --git a/input_data/MIMOC/util/convert_to_netCDF4_classic.sh b/input_data/MIMOC/util/convert_to_netCDF4_classic.sh new file mode 100644 index 0000000000000000000000000000000000000000..aace83ebf0d19b0806f1faa3b014cd845627e40d --- /dev/null +++ b/input_data/MIMOC/util/convert_to_netCDF4_classic.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +function _conv_to_netcdf4 { + infile=$1 + tmpfile=/tmp/_tmp_`date +%s%N`_`basename ${infile}` + nccopy -s -7 -d 1 \ + -c"SIG/1,LAT/90,LONG/90" \ + -c"PRES/1,LAT/90,LONG/90" \ + -c"LAT/90,LONG/90" \ + ${infile} ${tmpfile} + cdo diff ${tmpfile} ${infile} && mv ${tmpfile} ${infile} + echo "Converted ${infile} to deflated netCDF4 classic" +} + +export -f _conv_to_netcdf4 + +find data -type f -name \*.nc -print0 | \ + xargs -0 -n1 -P8 -I {} bash -c "_conv_to_netcdf4 {}"