Ignore:
Timestamp:
Jul 4, 2007, 5:22:18 PM (17 years ago)
Author:
nick
Message:

update model scripts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • anuga_work/production/onslow_2006/run_onslow_urs.py

    r4544 r4587  
    3939from anuga.caching import myhash
    4040from anuga.damage_modelling.inundation_damage import add_depth_and_momentum2csv, inundation_damage
     41from anuga.fit_interpolate.benchmark_least_squares import mem_usage
    4142
    4243# Application specific imports
     
    225226    kwargs['completed']=str(time.time()-t0)
    226227    '''
    227  #   if myid == 0:
    228 #        store_parameters(**kwargs)
    229    
    230    
    231     swwfile = kwargs['output_dir']+kwargs['aa_scenario_name']
    232     print 'swwfile',swwfile
    233     '''
    234     export_grid(swwfile, extra_name_out = 'town',
    235 #                quantities = ['depth'], # '(xmomentum**2 + ymomentum**2)**0.5' defaults to elevation
    236                 quantities = ['elevation','depth','stage','speed'], # '(xmomentum**2 + ymomentum**2)**0.5' defaults to elevation
     228    if myid == 0:
     229        #store_parameters(**kwargs)
     230       
     231        print 'memory usage before del domain',mem_usage()
     232        #del domain
     233        print 'memory usage after del domain',mem_usage()
     234   
     235   
     236        swwfile = kwargs['output_dir']+kwargs['aa_scenario_name']
     237        print 'swwfile',swwfile
     238   
     239        export_grid(swwfile, extra_name_out = 'town',
     240                quantities = ['speed'], # '(xmomentum**2 + ymomentum**2)**0.5' defaults to elevation
     241#                quantities = ['elevation','depth','stage','speed'], # '(xmomentum**2 + ymomentum**2)**0.5' defaults to elevation
    237242                timestep = None,
    238243                reduction = max,
     
    247252                datum = 'WGS84',
    248253                format = 'asc')
    249     '''
    250     buildings_filename = project_urs.buildings_filename
    251     buildings_filename_out = project_urs.buildings_filename_out
     254   
     255        buildings_filename = project_urs.buildings_filename
     256        buildings_filename_out = project_urs.buildings_filename_out
    252257               
    253     inundation_damage(swwfile+'.sww', buildings_filename, buildings_filename_out)
    254     print '\n Augmented building file written to %s \n' \
     258        #inundation_damage(swwfile+'.sww', buildings_filename, buildings_filename_out)
     259        print '\n Augmented building file written to %s \n' \
    255260           %buildings_filename_out
    256 #    barrier()
    257 
     261    barrier()
     262   
    258263#-------------------------------------------------------------
    259264if __name__ == "__main__":
Note: See TracChangeset for help on using the changeset viewer.