Changeset 510
- Timestamp:
- 11/13/13 16:35:50
- Files:
-
- raw2proc/trunk/raw2proc/b1_config_20111112.py (modified) (5 diffs)
- raw2proc/trunk/raw2proc/b2_config_20111112.py (modified) (5 diffs)
- raw2proc/trunk/raw2proc/billymitchell_config_20090623.py (deleted)
- raw2proc/trunk/raw2proc/billymitchell_config_20090624.py (added)
- raw2proc/trunk/raw2proc/billymitchell_config_20110607.py (modified) (3 diffs)
- raw2proc/trunk/raw2proc/billymitchell_config_20110914.py (modified) (3 diffs)
- raw2proc/trunk/raw2proc/billymitchell_config_20111013.py (added)
- raw2proc/trunk/raw2proc/billymitchell_config_20111019.py (added)
- raw2proc/trunk/raw2proc/billymitchell_config_20111029.py (modified) (3 diffs)
- raw2proc/trunk/raw2proc/billymitchell_config_20120416.py (modified) (3 diffs)
- raw2proc/trunk/raw2proc/billymitchell_config_20130202.py (added)
- raw2proc/trunk/raw2proc/ouba_config_20100701.py (modified) (1 diff)
- raw2proc/trunk/raw2proc/proc_codar_totals.py (modified) (5 diffs)
- raw2proc/trunk/raw2proc/proc_scintec_maindata_sfas.py (modified) (2 diffs)
- raw2proc/trunk/raw2proc/raw2proc.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
raw2proc/trunk/raw2proc/b1_config_20111112.py
r492 r510 31 31 'references' : 'http://nccoos.org', 32 32 'source': 'Buoy CR1000 Datalogger', 33 # Needed for processing NDBC output 34 'ndbc_module' : 'ndbc_41xxx', 35 'ndbc_id': '41xxx', 36 'ndbc_dir' : '/seacoos/data/nccoos/latest_ndbc', 37 'ndbc_missing' : -9999.0, 33 38 } 34 39 … … 48 53 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 49 54 # 'latest_vars' : ('time','lat','lon','z','atemp', 'baro', 'rh', 'rain', 'psp', 'pir'), 55 'ndbc_vars' : ('air_temp', 'air_press', 'rh', 'psp', 'pir'), 56 'ndbc_tags' : ('atmp1', 'baro1', 'rrh', 'srad1', 'lwrad'), 57 'ndbc_units' : ('degC', 'hPa', '%', 'W m-2', 'W m-2'), 50 58 'plot_module': 'plot_cr1000_met', 51 59 'plot_names': ('timeseries',), … … 66 74 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 67 75 # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 76 'ndbc_vars' : ('wspd1', 'wdir1', 'wgust1', 'wspd2', 'wdir2', 'wgust2'), 77 'ndbc_tags' : ('wspd1', 'wdir1', 'gust1', 'wspd2', 'wdir2', 'gust2'), 78 'ndbc_units' : ('m s-1', 'degrees', 'm s-1', 'm s-1', 'degrees', 'm s-1'), 68 79 'plot_module': 'plot_cr1000_wind', 69 80 'plot_names': ('timeseries',), … … 83 94 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 84 95 # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 96 'ndbc_vars' : ('wtemp','depth', 'wtemp', 'salin'), 97 # wtmp1 tag needed to get into weather obs, others for temp/salin obs 98 'ndbc_tags' : ('wtmp1', 'dp001', 'tp001', 'sp001'), 99 'ndbc_units' : ('degC', 'm', 'degC', 'psu'), 85 100 'plot_module': 'plot_cr1000_ctd', 86 101 'plot_names': ('timeseries',), … … 100 115 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 101 116 # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 117 'ndbc_vars' : ('depth', 'wtemp', 'salin'), 118 'ndbc_tags' : ('dp002', 'tp002', 'sp002'), 119 'ndbc_units' : ('m', 'degC', 'psu'), 102 120 'plot_module': 'plot_cr1000_ctd', 103 121 'plot_names': ('timeseries',), raw2proc/trunk/raw2proc/b2_config_20111112.py
r492 r510 31 31 'references' : 'http://nccoos.org', 32 32 'source': 'Buoy CR1000 Datalogger', 33 # Needed for processing NDBC output 34 'ndbc_module' : 'ndbc_41yyy', 35 'ndbc_id': '41yyy', 36 'ndbc_dir' : '/seacoos/data/nccoos/latest_ndbc', 37 'ndbc_missing' : -9999.0, 33 38 } 34 39 … … 49 54 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 50 55 # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 56 'ndbc_vars' : ('air_temp', 'air_press', 'rh', 'psp', 'pir'), 57 'ndbc_tags' : ('atmp1', 'baro1', 'rrh', 'srad1', 'lwrad'), 58 'ndbc_units' : ('degC', 'hPa', '%', 'W m-2', 'W m-2'), 51 59 'plot_module': 'plot_cr1000_met', 52 60 'plot_names': ('timeseries',), … … 67 75 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 68 76 # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 77 'ndbc_vars' : ('wspd1', 'wdir1', 'wgust1', 'wspd2', 'wdir2', 'wgust2'), 78 'ndbc_tags' : ('wspd1', 'wdir1', 'gust1', 'wspd2', 'wdir2', 'gust2'), 79 'ndbc_units' : ('m s-1', 'degrees', 'm s-1', 'm s-1', 'degrees', 'm s-1'), 69 80 'plot_module': 'plot_cr1000_wind', 70 81 'plot_names': ('timeseries',), … … 84 95 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 85 96 # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 97 'ndbc_vars' : ('wtemp','depth', 'wtemp', 'salin'), 98 # wtmp1 tag needed to get into weather obs, others for temp/salin obs 99 'ndbc_tags' : ('wtmp1', 'dp001', 'tp001', 'sp001'), 100 'ndbc_units' : ('degC', 'm', 'degC', 'psu'), 86 101 'plot_module': 'plot_cr1000_ctd', 87 102 'plot_names': ('timeseries',), … … 101 116 # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 102 117 # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 118 'ndbc_vars' : ('depth', 'wtemp', 'salin'), 119 'ndbc_tags' : ('dp002', 'tp002', 'sp002'), 120 'ndbc_units' : ('m', 'degC', 'psu'), 103 121 'plot_module': 'plot_cr1000_ctd', 104 122 'plot_names': ('timeseries',), raw2proc/trunk/raw2proc/billymitchell_config_20110607.py
r462 r510 1 # 2 # Increase number of altitudes to 59 (from 10 - 300 meters) 3 # 1 4 platform_info = { 2 5 'id' : 'billymitchell', … … 6 9 'mvar' : -10.783333, # degrees (-) west, (+) east 7 10 'institution' : 'nccoos', 8 'config_start_date' : '2011-06-07 00:00:00',9 'config_end_date' : '2011-08-2 6 00:00:00', # None or yyyy-mm-dd HH:MM:SS11 'config_start_date' : '2011-06-07 20:00:00', 12 'config_end_date' : '2011-08-25 14:30:00', # None or yyyy-mm-dd HH:MM:SS 10 13 'packages' : ('sfas',), 11 14 } … … 13 16 'sfas' : { 'id' : 'sodar', 14 17 'description' : 'Wind profile data', 15 'raw_dir' : '/seacoos/data/nccoos/level0/' 16 'billymitchell/sodar1/mnd', 18 'raw_dir' : '/seacoos/data/nccoos/level0/billymitchell/sodar1/mnd', 17 19 'raw_file_glob' : '*.mnd', 18 'proc_dir' : '/seacoos/data/nccoos/level1/' 19 'billymitchell/sodar1', 20 'proc_dir' : '/seacoos/data/nccoos/level1/billymitchell/sodar1', 20 21 'process_module' : 'proc_scintec_maindata_sfas', 21 22 'utc_offset' : 0, # hours offset to utc raw2proc/trunk/raw2proc/billymitchell_config_20110914.py
r478 r510 1 # 2 # Increase number of altitudes to 99 (from 10 - 500 meters) 3 # 1 4 platform_info = { 2 5 'id' : 'billymitchell', … … 6 9 'mvar' : -10.783333, # degrees (-) west, (+) east 7 10 'institution' : 'nccoos', 8 'config_start_date' : '2011-09-14 00:00:00',9 'config_end_date' : '2011-10- 29 00:00:00', # None or yyyy-mm-dd HH:MM:SS11 'config_start_date' : '2011-09-14 19:00:00', 12 'config_end_date' : '2011-10-13 19:30:00', # None or yyyy-mm-dd HH:MM:SS 10 13 'packages' : ('sfas',), 11 14 } … … 13 16 'sfas' : { 'id' : 'sodar', 14 17 'description' : 'Wind profile data', 15 'raw_dir' : '/seacoos/data/nccoos/level0/' 16 'billymitchell/sodar1/mnd', 18 'raw_dir' : '/seacoos/data/nccoos/level0/billymitchell/sodar1/mnd', 17 19 'raw_file_glob' : '*.mnd', 18 'proc_dir' : '/seacoos/data/nccoos/level1/' 19 'billymitchell/sodar1', 20 'proc_dir' : '/seacoos/data/nccoos/level1/billymitchell/sodar1', 20 21 'process_module' : 'proc_scintec_maindata_sfas', 21 22 'utc_offset' : 0, # hours offset to utc raw2proc/trunk/raw2proc/billymitchell_config_20111029.py
r493 r510 1 # 2 # Decrease number of altitudes to 37 (from 15 - 195 meters) 3 # 1 4 platform_info = { 2 5 'id' : 'billymitchell', … … 7 10 'institution' : 'nccoos', 8 11 'config_start_date' : '2011-10-29 00:30:00', 9 'config_end_date' : '2012-04-16 1 9:00:00', # None or yyyy-mm-dd HH:MM:SS12 'config_end_date' : '2012-04-16 18:30:00', # None or yyyy-mm-dd HH:MM:SS 10 13 'packages' : ('sfas',), 11 14 } … … 13 16 'sfas' : { 'id' : 'sodar', 14 17 'description' : 'Wind profile data', 15 'raw_dir' : '/seacoos/data/nccoos/level0/' 16 'billymitchell/sodar1/mnd', 18 'raw_dir' : '/seacoos/data/nccoos/level0/billymitchell/sodar1/mnd', 17 19 'raw_file_glob' : '*.mnd', 18 'proc_dir' : '/seacoos/data/nccoos/level1/' 19 'billymitchell/sodar1', 20 'proc_dir' : '/seacoos/data/nccoos/level1/billymitchell/sodar1', 20 21 'process_module' : 'proc_scintec_maindata_sfas', 21 22 'utc_offset' : 0, # hours offset to utc raw2proc/trunk/raw2proc/billymitchell_config_20120416.py
r493 r510 1 # 2 # Increase number of altitudes to 39 (from 10 - 200 meters) 3 # 1 4 platform_info = { 2 5 'id' : 'billymitchell', … … 6 9 'mvar' : -10.783333, # degrees (-) west, (+) east 7 10 'institution' : 'nccoos', 8 'config_start_date' : '2012-04-16 19:30:00',9 'config_end_date' : None, # None or yyyy-mm-dd HH:MM:SS11 'config_start_date' : '2012-04-16 20:30:00', 12 'config_end_date' : '2012-07-23 12:00:00', # None or yyyy-mm-dd HH:MM:SS 10 13 'packages' : ('sfas',), 11 14 } … … 13 16 'sfas' : { 'id' : 'sodar', 14 17 'description' : 'Wind profile data', 15 'raw_dir' : '/seacoos/data/nccoos/level0/' 16 'billymitchell/sodar1/mnd', 18 'raw_dir' : '/seacoos/data/nccoos/level0/billymitchell/sodar1/mnd', 17 19 'raw_file_glob' : '*.mnd', 18 'proc_dir' : '/seacoos/data/nccoos/level1/' 19 'billymitchell/sodar1', 20 'proc_dir' : '/seacoos/data/nccoos/level1/billymitchell/sodar1', 20 21 'process_module' : 'proc_scintec_maindata_sfas', 21 22 'utc_offset' : 0, # hours offset to utc raw2proc/trunk/raw2proc/ouba_config_20100701.py
r336 r510 13 13 # 14 14 'config_start_date' : '2010-07-01 00:00:00', 15 'config_end_date' : None, # None or yyyy-mm-dd HH:MM:SS15 'config_end_date' : '2013-10-31 23:00:00', # None or yyyy-mm-dd HH:MM:SS 16 16 'packages' : ('hfr', ), 17 17 } raw2proc/trunk/raw2proc/proc_codar_totals.py
r490 r510 1 1 #!/usr/bin/env python 2 # Last modified: Time-stamp: <201 2-05-01 10:39:23haines>2 # Last modified: Time-stamp: <2013-04-30 16:27:48 haines> 3 3 """ 4 4 how to parse data, and assert what data and info goes into … … 67 67 yi = numpy.linspace(minlat, maxlat, nlat) 68 68 xi = numpy.linspace(minlon, maxlon, nlon) 69 xmesh, ymesh = numpy.meshgrid(xi, yi) 69 70 70 71 data = { … … 77 78 } 78 79 79 sample_dt, ftype, ncol, nrow = (None, None, None, None)80 sample_dt, ftype, lluvspec, ncol, nrow = (None, None, None, None, None) 80 81 # read header that match '%(k): (v)\n' pairs on each line 81 82 m = re.findall(r'^(%.*):\s*(.*)$', ''.join(lines), re.MULTILINE) … … 85 86 elif k == '%TableType': 86 87 ftype = v 88 elif k == '%LLUVSpec': 89 lluvspec = float(re.split('\s+', v)[0]) 87 90 elif k == '%TableColumns': 88 91 ncol = int(v) 89 92 elif k == '%TableRows': 90 93 nrow = int(v) 94 elif k == '%TableEnd': 95 break 96 # LLUVSpec 1.17 and greater has two tables bracketed by TableStart and TableEnd 97 # get out of this search loop after the first table 91 98 92 99 if nrow>2: … … 112 119 vel_mag = d[:,12] 113 120 vel_dir = d[:,13] 114 s1 = d[:,14] 115 s2 = d[:,15] 116 s3 = d[:,16] 117 s4 = d[:,17] 118 s5 = d[:,18] 119 s6 = d[:,19] 121 122 # ibad = (wu_std_qual==999.) | (wv_std_qual==999.) | (cov_qual==999.) 123 # wu[ibad] = numpy.nan 124 # wv[ibad] = numpy.nan 125 126 # SMH -- April 26, 2013 -- commenting out these columns for now until figure out how to handle 127 # new dynamic form of LLUVSpec 1.17 in TOT4 format, prior versions were static with 6 fields 128 # will have to use %LLUVSpec header info and second table at bottom of file to get dynamic ncols 129 # s1 = d[:,14] 130 # s2 = d[:,15] 131 # s3 = d[:,16] 132 # s4 = d[:,17] 133 # s5 = d[:,18] 134 # s6 = d[:,19] 120 135 121 136 try: 122 uim = griddata(lon, lat, wu, x i, yi)123 vim = griddata(lon, lat, wv, x i, yi)137 uim = griddata(lon, lat, wu, xmesh, ymesh) 138 vim = griddata(lon, lat, wv, xmesh, ymesh) 124 139 # returned masked array as an ndarray with masked values filled with fill_value 125 140 ui = uim.filled(fill_value=numpy.nan) raw2proc/trunk/raw2proc/proc_scintec_maindata_sfas.py
r309 r510 76 76 radial = float(radial) 77 77 data['u'][profile_index][observation_index] = \ 78 radial * math.sin(theta)78 -radial * math.sin(theta) 79 79 data['v'][profile_index][observation_index] = \ 80 radial * math.cos(theta)80 -radial * math.cos(theta) 81 81 82 82 for variable in profile.variables: … … 168 168 'long_name': 'East/West Component of Wind', 169 169 'standard_name': 'eastward_wind', 170 'positive': 'to the east', 170 171 'units': 'm s-1', 171 172 }, 172 173 'v': {'short_name' : 'v', 173 174 'long_name': 'North/South Component of Wind', 174 'standard_name': 'northward_wind', 175 'standard_name': 'northward_wind', 176 'positive': 'to the north', 175 177 'units': 'm s-1', 176 178 }, 177 179 'w': {'short_name' : 'w', 178 180 'long_name': 'Vertical Component of Wind', 179 'standard_name': 'upward_wind', 181 'standard_name': 'upward_wind', 182 'positive': 'from the surface', 180 183 'units': 'm s-1', 181 184 }, raw2proc/trunk/raw2proc/raw2proc.py
r492 r510 1 1 #!/usr/bin/env python 2 # Last modified: Time-stamp: <201 2-06-01 17:01:51haines>2 # Last modified: Time-stamp: <2013-11-05 16:37:38 haines> 3 3 """Process raw data to monthly netCDF data files 4 4