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

Changeset 491

Show
Ignore:
Timestamp:
05/01/12 16:47:44
Author:
haines
Message:

--

Files:

Legend:

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

    r490 r491  
    7171              'raw_file_glob' : '*.dat', 
    7272              'proc_dir' : '/seacoos/data/nccoos/level1/b2/ctd1/', 
    73               'process_module' : 'proc_cr1000_ctd', 
     73              'process_module' : 'proc_cr1000_ctd_v1', 
    7474              'utc_offset' : 0,  # hours offset to utc of sampling time 
    7575              'nominal_depth' : -2.0,  # meters  
     
    8686              'raw_file_glob' : '*.dat', 
    8787              'proc_dir' : '/seacoos/data/nccoos/level1/b2/ctd2/', 
    88               'process_module' : 'proc_cr1000_ctd', 
     88              'process_module' : 'proc_cr1000_ctd_v1', 
    8989              'utc_offset' : 0,  # hours offset to utc of sampling time 
    9090              'nominal_depth' : -15.0,  # meters  
  • raw2proc/trunk/raw2proc/b2_config_20111112.py

    r490 r491  
    8383    'ctd2' : { 'id' : 'ctd2', 
    8484               'description' : 'Mid-level CTD Data each sample period', 
    85               'raw_dir' : '/seacoos/data/nccoos/level0/b2/ctd2/sotre/2011_11', 
     85              'raw_dir' : '/seacoos/data/nccoos/level0/b2/ctd2/store/2011_11', 
    8686              'raw_file_glob' : '*', 
    8787              'proc_dir' : '/seacoos/data/nccoos/level1/b2/ctd2/', 
  • raw2proc/trunk/raw2proc/proc_cr1000_ctd_v1.py

    r490 r491  
    11#!/usr/bin/env python 
    2 # Last modified:  Time-stamp: <2012-04-23 14:12:55 haines> 
     2# Last modified:  Time-stamp: <2012-05-01 16:12:51 haines> 
    33""" 
    44how to parse data, and assert what data and info goes into 
     
    4141    "TS","RN","","","","","","","" 
    4242    "","","Smp","Smp","Smp","Smp","Smp","Smp","Smp" 
    43     "2011-12-01 00:02:09",4449,3585,16.1596,4.15704,3.413," 30 Nov 2011"," 23:58:44","   4406 " 
    44     "2011-12-01 00:08:09",4450,3585,16.1783,4.15878,3.745," 01 Dec 2011"," 00:04:44","   4407 " 
    45     "2011-12-01 00:14:09",4451,3585,16.1638,4.15794,3.545," 01 Dec 2011"," 00:10:44","   4408 " 
    46     "2011-12-01 00:20:09",4452,3585,16.1632,4.15769,3.254," 01 Dec 2011"," 00:16:44","   4409 " 
    47     "2011-12-01 00:26:09",4453,3585,16.1524,4.15665,3.649," 01 Dec 2011"," 00:22:44","   4410 " 
    48     "2011-12-01 00:32:09",4454,3585,16.1661,4.1582,3.277," 01 Dec 2011"," 00:28:44","   4411 " 
     43    "2011-10-05 21:08:06",43,4085,24.5027,5.18209,3.347 
     44    "2011-10-05 21:14:06",44,4085,24.5078,5.18305,3.454 
     45    "2011-10-05 21:56:07",45,4085,24.5247,5.19257,3.423 
     46    "2011-10-05 22:02:06",46,4085,24.5105,5.18714,3.526 
     47    "2011-10-05 22:08:07",47,4085,24.519,5.19096,3.547 
     48    "2011-10-05 22:14:06",48,4085,24.5207,5.19172,3.508 
     49 
    4950    """ 
    5051 
     
    9596                csi.append(float(m.groups()[0])) 
    9697 
    97         if len(sw)>=9
    98             dstr = re.sub('"', '', sw[6]+' '+sw[7]) 
     98        if len(sw)>=6
     99            dstr = re.sub('"', '', sw[0]) 
    99100            # print dstr 
    100             m = re.search('\s*(\d{2})\s*(\w{2,3})\s*(\d{4})\s*(\d{2}):(\d{2}):(\d{2})', dstr) 
    101101        else: 
    102102            print ' ... skipping line %d -- %s ' % (i,line) 
    103103            continue             
    104104 
    105         if m: 
    106             dstr = '%s %s %s %s:%s:%s' % m.groups() 
    107         else: 
    108             print ' ... skipping line %d -- %s ' % (i,line) 
    109             continue             
    110  
    111105        if  sensor_info['utc_offset']: 
    112             sample_dt = scanf_datetime(dstr, fmt='%d %b %Y %H:%M:%S') + \ 
     106            sample_dt = scanf_datetime(dstr, fmt='%Y-%m-%d %H:%M:%S') + \ 
    113107                        timedelta(hours=sensor_info['utc_offset']) 
    114108        else: 
    115             sample_dt = scanf_datetime(dstr, fmt='%d %b %Y %H:%M:%S') 
     109            sample_dt = scanf_datetime(dstr, fmt='%Y-%m-%d %H:%M:%S') 
    116110 
    117111        # ***** TO DO: need to adjust any drift of offset in CTD sample time to CR1000 clock 
  • raw2proc/trunk/raw2proc/raw2proc.py

    r490 r491  
    11#!/usr/bin/env python 
    2 # Last modified:  Time-stamp: <2012-05-01 11:58:23 haines> 
     2# Last modified:  Time-stamp: <2012-05-01 16:40:55 haines> 
    33"""Process raw data to monthly netCDF data files 
    44 
     
    291291        else: 
    292292            platforms = [plats] # make one platform iterable 
     293    else: platforms = plats 
    293294         
    294295    print ' Expanded lists for creating spin_list:' 
     
    305306            else: 
    306307                packages = [packs] # make one package iterable 
     308        else: packages = packs 
    307309 
    308310        print ' ... ... packages : %s' % packages 
     
    603605                ofn = os.path.join(si['proc_dir'], si['proc_filename']) 
    604606                (raw_files, raw_dts) = find_raw(si, yyyy_mm) 
    605                 print raw_files 
    606                 print raw_dts 
     607                # print raw_files 
     608                # print raw_dts 
    607609                raw_files = which_raw(pi, raw_files, raw_dts) 
    608                 print raw_files 
    609                 print raw_dts 
     610                # print raw_files 
     611                # print raw_dts 
    610612                # remove any previous netcdf file (platform_package_yyyy_mm.nc) 
    611613                if index==0  and os.path.exists(ofn): 
  • raw2proc/trunk/raw2proc/spin/spin_billymitchell_sfas.py

    r465 r491  
    44from raw2proc import * 
    55 
    6 raw2proc('manual', 'billymitchell', 'sfas', '2009_06') 
    7 raw2proc('manual', 'billymitchell', 'sfas', '2009_07') 
    8 raw2proc('manual', 'billymitchell', 'sfas', '2009_08') 
    9 raw2proc('manual', 'billymitchell', 'sfas', '2009_09') 
    10 raw2proc('manual', 'billymitchell', 'sfas', '2009_10') 
    11 raw2proc('manual', 'billymitchell', 'sfas', '2009_11') 
    12 raw2proc('manual', 'billymitchell', 'sfas', '2009_12') 
    13 raw2proc('manual', 'billymitchell', 'sfas', '2010_01') 
    14 raw2proc('manual', 'billymitchell', 'sfas', '2010_02') 
    15 raw2proc('manual', 'billymitchell', 'sfas', '2010_03') 
    16 raw2proc('manual', 'billymitchell', 'sfas', '2010_04') 
    17 raw2proc('manual', 'billymitchell', 'sfas', '2010_05') 
    18 raw2proc('manual', 'billymitchell', 'sfas', '2010_06') 
    19 raw2proc('manual', 'billymitchell', 'sfas', '2010_07') 
    20 raw2proc('manual', 'billymitchell', 'sfas', '2010_08') 
    21 raw2proc('manual', 'billymitchell', 'sfas', '2010_09') 
    22 raw2proc('manual', 'billymitchell', 'sfas', '2011_06') 
    23 raw2proc('manual', 'billymitchell', 'sfas', '2011_07') 
    24 raw2proc('manual', 'billymitchell', 'sfas', '2011_08') 
    25 raw2proc('manual', 'billymitchell', 'sfas', '2011_09') 
    26 raw2proc('manual', 'billymitchell', 'sfas', '2011_10') 
     6# raw2proc('manual', 'billymitchell', 'sfas', '2009_06') 
     7# raw2proc('manual', 'billymitchell', 'sfas', '2009_07') 
     8# raw2proc('manual', 'billymitchell', 'sfas', '2009_08') 
     9# raw2proc('manual', 'billymitchell', 'sfas', '2009_09') 
     10# raw2proc('manual', 'billymitchell', 'sfas', '2009_10') 
     11# raw2proc('manual', 'billymitchell', 'sfas', '2009_11') 
     12# raw2proc('manual', 'billymitchell', 'sfas', '2009_12') 
     13# raw2proc('manual', 'billymitchell', 'sfas', '2010_01') 
     14# raw2proc('manual', 'billymitchell', 'sfas', '2010_02') 
     15# raw2proc('manual', 'billymitchell', 'sfas', '2010_03') 
     16# raw2proc('manual', 'billymitchell', 'sfas', '2010_04') 
     17# raw2proc('manual', 'billymitchell', 'sfas', '2010_05') 
     18# raw2proc('manual', 'billymitchell', 'sfas', '2010_06') 
     19# raw2proc('manual', 'billymitchell', 'sfas', '2010_07') 
     20# raw2proc('manual', 'billymitchell', 'sfas', '2010_08') 
     21# raw2proc('manual', 'billymitchell', 'sfas', '2010_09') 
     22# raw2proc('manual', 'billymitchell', 'sfas', '2011_06') 
     23# raw2proc('manual', 'billymitchell', 'sfas', '2011_07') 
     24# raw2proc('manual', 'billymitchell', 'sfas', '2011_08') 
     25# raw2proc('manual', 'billymitchell', 'sfas', '2011_09') 
     26# raw2proc('manual', 'billymitchell', 'sfas', '2011_10') 
     27# raw2proc('manual', 'billymitchell', 'sfas', '2011_11') 
     28raw2proc('manual', 'billymitchell', 'sfas', '2011_12') 
     29raw2proc('manual', 'billymitchell', 'sfas', '2012_01') 
     30raw2proc('manual', 'billymitchell', 'sfas', '2012_02')