Changeset 6255
- Timestamp:
- Jan 31, 2009, 5:16:00 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_work/production/busselton/standardised_version/run_busselton.py
r6254 r6255 78 78 79 79 # Read in boundary from ordered sts file 80 urs_bounding_polygon=create_sts_boundary(os.path.join(project.boundaries_dir_event, project.scenario_name))80 urs_bounding_polygon=create_sts_boundary(os.path.join(project.boundaries_dir_event, project.scenario_name)) 81 81 82 82 # Reading the landward defined points, this incorporates the original clipping … … 125 125 print 'triangles',len(domain) 126 126 127 kwargs['act_num_trigs']=len(domain)128 127 129 128 … … 134 133 135 134 # sets the initial stage in the offcoast region only 136 IC = Polygon_function( [(project.poly_mainland, 0),(project.poly_marina, 0)], default = kwargs['tide'], 137 geo_reference = domain.geo_reference) 135 IC = Polygon_function( [(project.poly_mainland, 0), 136 (project.poly_marina, 0)], 137 default = project.tide, 138 geo_reference = domain.geo_reference) 138 139 domain.set_quantity('stage', IC) 139 #domain.set_quantity('stage',kwargs['tide'] ) 140 domain.set_quantity('friction', kwargs['friction'])140 141 domain.set_quantity('friction', project.friction) 141 142 142 143 print 'Start Set quantity',kwargs['elevation_file'] … … 146 147 use_cache = False, 147 148 verbose = True, 148 alpha = kwargs['alpha'])149 alpha = project.alpha) 149 150 print 'Finished Set quantity' 150 151 … … 160 161 #------------------------------------------------------ 161 162 print 'domain id', id(domain) 162 domain.set_name( kwargs['scenario_name'])163 domain.set_name(project.scenario_name) 163 164 domain.set_datadir(kwargs['output_dir']) 164 165 domain.set_default_order(2) # Apply second order scheme … … 178 179 179 180 Br = Reflective_boundary(domain) 180 Bd = Dirichlet_boundary( [kwargs['tide'],0,0])181 Bd = Dirichlet_boundary(project.tide,0,0]) 181 182 182 183 print 'Available boundary tags', domain.get_boundary_tags() … … 193 194 'ocean': Bf}) 194 195 195 kwargs['input_start_time']=domain.starttime196 196 197 197 print'finish set boundary' … … 202 202 t0 = time.time() 203 203 204 for t in domain.evolve(yieldstep = project.yieldstep, finaltime = kwargs['finaltime'] 205 ,skip_initial_step = False): 204 for t in domain.evolve(yieldstep=project.yieldstep, 205 finaltime=project.finaltime, 206 skip_initial_step=False): 206 207 domain.write_time() 207 208 domain.write_boundary_statistics(tags = 'ocean') … … 214 215 print 'Simulation took %.2f seconds' %(time.time()-t0) 215 216 216 #kwargs 'completed' must be added to write the final parameters to file 217 217 218 kwargs['completed']=str(time.time()-t0) 218 219 219 220 store_parameters(**kwargs) 220 221 print 'memory usage before del domain1',mem_usage() 221 222 222 223 223 … … 227 227 kwargs={} 228 228 kwargs['file_name']=project.dir_comment 229 kwargs['finaltime']=project.finaltime230 229 kwargs['output_dir']=project.output_run_time_dir 231 230 kwargs['elevation_file']=project.combined_dir_name+'.pts' 232 kwargs['scenario_name']=project.scenario_name233 kwargs['tide']=project.tide234 kwargs['alpha'] = project.alpha235 kwargs['friction']=project.friction236 #kwargs['num_cpu']=numprocs237 #kwargs['host']=project.host238 #kwargs['starttime']=project.starttime239 #kwargs['yieldstep']=project.yieldstep240 #kwargs['user']=project.user241 #kwargs['time_thinning'] = project.time_thinning242 231 243 232 run_model(**kwargs)
Note: See TracChangeset
for help on using the changeset viewer.