NCCOOS Trac Projects: Top | Web | Platforms | Processing | Viz | Sprints | Sandbox | (Wind)

Changeset 492

Show
Ignore:
Timestamp:
06/14/12 10:33:14
Author:
haines
Message:

minor to raw2proc:which_raw()

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • raw2proc/trunk/raw2proc/b1_config_20111112.py

    r490 r492  
    1313            'institution' : 'nccoos', 
    1414            # 
    15             'config_start_date' : '2011-11-13 00:00:00', 
    16             'config_end_date' : '2012-04-09 00:00:00', # None or yyyy-mm-dd HH:MM:SS 
     15            'config_start_date' : '2011-11-12 16:00:00', 
     16            'config_end_date' : '2012-04-08 19:00:00', # None or yyyy-mm-dd HH:MM:SS 
    1717            'packages' : ('met', 'wind', 'ctd1', 'ctd2'), 
    1818            # Required by CF 
     
    4545              'height_units' : 'm', 
    4646              'height_reference' : 'sea_surface', 
     47              'source': 'Heise Baro, Rotronics Temp/RH, RM Young Precip, Eppley PSP/PIR', 
    4748              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    4849              # 'latest_vars' : ('time','lat','lon','z','atemp', 'baro', 'rh', 'rain', 'psp', 'pir'), 
    49               # Recommended 
    50               'source': 'Heise Baro, Rotronics Temp/RH, RM Young Precip, Eppley PSP/PIR'
     50              'plot_module': 'plot_cr1000_met', 
     51              'plot_names': ('timeseries',)
    5152             }, 
    5253    'wind' : { 'id' : 'wind', 
     
    6162              'height_units' : 'm', 
    6263              'height_reference' : 'sea_surface', 
     64              # Recommended 
     65              'source': 'RM Young Marine Wind Monitor 5106', 
    6366              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    6467              # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 
    65               # Recommended 
    66               'source': 'RM Young Marine Wind Monitor 5106'
     68              'plot_module': 'plot_cr1000_wind', 
     69              'plot_names': ('timeseries',)
    6770             }, 
    6871    'ctd1' : { 'id' : 'ctd1', 
     
    7679              'depth_units' : 'm', 
    7780              'depth_reference' : 'sea_surface', 
     81              # Recommended 
     82              'source': 'Seabird (SBE) 37 IMP', 
    7883              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    7984              # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 
    80               # Recommended 
    81               'source': 'Seabird (SBE) 37 IMP'
     85              'plot_module': 'plot_cr1000_ctd', 
     86              'plot_names': ('timeseries',)
    8287             }, 
    8388    'ctd2' : { 'id' : 'ctd2', 
     
    9196              'depth_units' : 'm', 
    9297              'depth_reference' : 'sea_surface', 
     98              # Recommended 
     99              'source': 'Seabird (SBE) 37 IMP', 
    93100              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    94101              # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 
    95               # Recommended 
    96               'source': 'Seabird (SBE) 37 IMP'
     102              'plot_module': 'plot_cr1000_ctd', 
     103              'plot_names': ('timeseries',)
    97104             }, 
    98105    } 
  • raw2proc/trunk/raw2proc/b2_config_20111005.py

    r491 r492  
    1313            'institution' : 'nccoos', 
    1414            # 
    15             'config_start_date' : '2011-10-06 00:00:00', 
     15            'config_start_date' : '2011-10-05 22:00:00', 
    1616            'config_end_date' : '2011-11-13 00:00:00', # None or yyyy-mm-dd HH:MM:SS 
    1717            'packages' : ('met', 'wind', 'ctd1', 'ctd2'), 
     
    4545              'height_units' : 'm', 
    4646              'height_reference' : 'sea_surface', 
     47              # Recommended 
     48              'source': 'Heise Baro, Rotronics Temp/RH, RM Young Precip, Eppley PSP/PIR', 
    4749              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    4850              # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 
    49               # Recommended 
    50               'source': 'Heise Baro, Rotronics Temp/RH, RM Young Precip, Eppley PSP/PIR'
     51              'plot_module': 'plot_cr1000_met', 
     52              'plot_names': ('timeseries',)
    5153             }, 
    5254    'wind' : { 'id' : 'wind', 
     
    6163              'height_units' : 'm', 
    6264              'height_reference' : 'sea_surface', 
     65              # Recommended 
     66              'source': 'RM Young Marine Wind Monitor 5106', 
    6367              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    6468              # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 
    65               # Recommended 
    66               'source': 'RM Young Marine Wind Monitor 5106'
     69              'plot_module': 'plot_cr1000_wind', 
     70              'plot_names': ('timeseries',)
    6771             }, 
    6872    'ctd1' : { 'id' : 'ctd1', 
     
    7680              'depth_units' : 'm', 
    7781              'depth_reference' : 'sea_surface', 
     82              # Recommended 
     83              'source': 'Seabird (SBE) 37 IMP', 
    7884              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    7985              # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 
    80               # Recommended 
    81               'source': 'Seabird (SBE) 37 IMP'
     86              'plot_module': 'plot_cr1000_ctd', 
     87              'plot_names': ('timeseries',)
    8288             }, 
    8389    'ctd2' : { 'id' : 'ctd2', 
     
    9197              'depth_units' : 'm', 
    9298              'depth_reference' : 'sea_surface', 
     99              # Recommended 
     100              'source': 'Seabird (SBE) 37 IMP', 
    93101              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    94102              # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 
    95               # Recommended 
    96               'source': 'Seabird (SBE) 37 IMP'
     103              'plot_module': 'plot_cr1000_ctd', 
     104              'plot_names': ('timeseries',)
    97105             }, 
    98106    } 
  • raw2proc/trunk/raw2proc/b2_config_20111112.py

    r491 r492  
    1313            'institution' : 'nccoos', 
    1414            # 
    15             'config_start_date' : '2011-11-12 00:00:00', 
    16             'config_end_date' : '2012-04-04 00:00:00', # None or yyyy-mm-dd HH:MM:SS 
     15            'config_start_date' : '2011-11-13 00:00:00', 
     16            'config_end_date' : '2012-04-03 20:00:00', # None or yyyy-mm-dd HH:MM:SS 
    1717            'packages' : ('met', 'wind', 'ctd1', 'ctd2'), 
    1818            # Required by CF 
     
    4545              'height_units' : 'm', 
    4646              'height_reference' : 'sea_surface', 
     47              # Recommended 
     48              'source': 'Heise Baro, Rotronics Temp/RH, RM Young Precip, Eppley PSP/PIR', 
    4749              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    4850              # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 
    49               # Recommended 
    50               'source': 'Heise Baro, Rotronics Temp/RH, RM Young Precip, Eppley PSP/PIR'
     51              'plot_module': 'plot_cr1000_met', 
     52              'plot_names': ('timeseries',)
    5153             }, 
    5254    'wind' : { 'id' : 'wind', 
     
    6163              'height_units' : 'm', 
    6264              'height_reference' : 'sea_surface', 
     65              # Recommended 
     66              'source': 'RM Young Marine Wind Monitor 5106', 
    6367              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    6468              # 'latest_vars' : ('time','lat','lon','z','u', 'v', 'wspd', 'wdir'), 
    65               # Recommended 
    66               'source': 'RM Young Marine Wind Monitor 5106'
     69              'plot_module': 'plot_cr1000_wind', 
     70              'plot_names': ('timeseries',)
    6771             }, 
    6872    'ctd1' : { 'id' : 'ctd1', 
     
    7680              'depth_units' : 'm', 
    7781              'depth_reference' : 'sea_surface', 
     82              # Recommended 
     83              'source': 'Seabird (SBE) 37 IMP', 
    7884              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    7985              # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 
    80               # Recommended 
    81               'source': 'Seabird (SBE) 37 IMP'
     86              'plot_module': 'plot_cr1000_ctd', 
     87              'plot_names': ('timeseries',)
    8288             }, 
    8389    'ctd2' : { 'id' : 'ctd2', 
     
    9197              'depth_units' : 'm', 
    9298              'depth_reference' : 'sea_surface', 
     99              # Recommended 
     100              'source': 'Seabird (SBE) 37 IMP', 
    93101              # 'latest_dir' : '/seacoos/data/nccoos/latest_v2.0', 
    94102              # 'latest_vars' : ('time','lat','lon','z','depth', 'wtemp', 'cond', 'salin', 'density'), 
    95               # Recommended 
    96               'source': 'Seabird (SBE) 37 IMP'
     103              'plot_module': 'plot_cr1000_ctd', 
     104              'plot_names': ('timeseries',)
    97105             }, 
    98106    } 
  • raw2proc/trunk/raw2proc/crow_config_20090122.py

    r448 r492  
    2525               'utc_offset' : 4,      # hours offset to utc 
    2626               'press_offset' : 0./12., # pressure gauge offset to staff gauge 
    27                'plot_module' : 'crow_flow_plot',  
     27               'plot_module' : 'plot_cr1000_flow',  
    2828               'plot_names' : ('timeseries',),  
    2929               'csv_dir' : '/seacoos/data/nccoos/latest_csv', 
     
    4141            'process_module' : 'proc_cr1000_wq', 
    4242            'utc_offset' : 4,  # hours offset to utc 
    43             'plot_module' : 'crow_wq_plot',  
     43            'plot_module' : 'plot_cr1000_wq',  
    4444            'plot_names' : ('timeseries',),  
    4545            'csv_dir' : '/seacoos/data/nccoos/latest_csv', 
  • raw2proc/trunk/raw2proc/meet_config_20090122.py

    r320 r492  
    2525               'utc_offset' : 4,      # hours offset to utc 
    2626               'press_offset' : 0./12., # pressure gauge offset to staff gauge 
    27                'plot_module' : 'meet_flow_plot',  
     27               'plot_module' : 'plot_cr1000_flow',  
    2828               'plot_names' : ('timeseries',),  
    2929               'csv_dir' : '/seacoos/data/nccoos/latest_csv', 
     
    3737            'process_module' : 'proc_cr1000_wq', 
    3838            'utc_offset' : 4,  # hours offset to utc 
    39             'plot_module' : 'meet_wq_plot',  
     39            'plot_module' : 'plot_cr1000_wq',  
    4040            'plot_names' : ('timeseries',),  
    4141            'csv_dir' : '/seacoos/data/nccoos/latest_csv', 
  • raw2proc/trunk/raw2proc/proc_cr1000_met.py

    r488 r492  
    11#!/usr/bin/env python 
    2 # Last modified:  Time-stamp: <2012-04-23 14:12:38 haines> 
     2# Last modified:  Time-stamp: <2012-05-15 15:44:51 haines> 
    33""" 
    44how to parse data, and assert what data and info goes into 
     
    113113            #  
    114114            # data['samplenum'][i] = csi[0] # sample number assigned by datalogger in table 
    115             data['air_press'][i] = csi[1] # Heise Barometer (mbar) 
     115            data['air_press'][i] = csi[1] # Heise Barometer (psi) to mbar 
    116116            data['rh'][i] = csi[2] # relative humidity avg (60 samples for 1 min) 
    117117            data['rh_std'][i] = csi[3] # relative humidity std 
    118118            data['air_temp'][i] = csi[4] # air temperature avg (deg C) 
    119119            data['air_temp_std'][i] = csi[5] # air temperature std (deg C) 
    120             data['rain'][i] = csi[6] # precip gauge cummulative  
     120            data['rain'][i] = csi[6]/100. # precip gauge cummulative (mm)  
    121121            data['psp'][i] = csi[7] # PSP avg  
    122122            data['psp_std'][i] = csi[8] # PSP std 
     
    131131    # for line 
    132132 
     133    data['air_press'] = udconvert(data['air_press'], 'psi', 'mbar')[0] 
     134    # cannot figure out how to combine the two operations 
     135    # for some reason, this one liner does not work 
     136    # good = -40<at & at<60  
     137    above_tol=-40<data['air_temp'] 
     138    below_tol=data['air_temp']<60 
     139    good = above_tol & below_tol 
     140    bad = ~good 
     141    data['air_temp'][bad] = numpy.nan  
    133142 
    134143    # check that no data[dt] is set to Nan or anything but datetime 
  • raw2proc/trunk/raw2proc/procutil.py

    r488 r492  
    11#!/usr/bin/env python 
    2 # Last modified:  Time-stamp: <2012-04-17 12:09:47 haines> 
     2# Last modified:  Time-stamp: <2012-05-15 10:51:49 haines> 
    33"""Utilities to help data processing  
    44 
  • raw2proc/trunk/raw2proc/raw2proc.py

    r491 r492  
    11#!/usr/bin/env python 
    2 # Last modified:  Time-stamp: <2012-05-01 16:40:55 haines> 
     2# Last modified:  Time-stamp: <2012-06-01 17:01:51 haines> 
    33"""Process raw data to monthly netCDF data files 
    44 
     
    362362    # list all the raw files in prev-month, this-month, and next-month 
    363363    all_raw_files = [] 
    364     m = re.search('\d{4}_\d{2}$', si['raw_dir']) 
     364    m = re.search('\d{4}_\d{2}\/*$', si['raw_dir']) 
    365365    if m: 
    366366        # look for raw_file_glob in specific directory ending in YYYY_MM 
     
    377377             
    378378    all_raw_files.sort() 
    379          
     379     
    380380    #  
    381381    dt_start = si['proc_start_dt']-timedelta(days=1) 
     
    385385    for fn in all_raw_files: 
    386386        (fndt, granularity) = filt_datetime(os.path.basename(fn), gran=True) 
     387        # print (fndt, granularity) 
    387388        if granularity == 4: 
    388389            # change dt_start to before monthly filename filt_datetime() date