Changeset 7877
- Timestamp:
- Jun 29, 2010, 11:26:45 AM (15 years ago)
- Location:
- trunk
- Files:
-
- 1 deleted
- 14 edited
- 90 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/anuga_core/benchmarks/benchmark_sww2dem.py
r7813 r7877 4 4 """ 5 5 6 from anuga.file_conversion.sww2dem import sww2dem 7 from create_test_sww import create_test_sww 6 import anuga 8 7 import os.path 9 8 import cProfile 10 9 import time 11 10 11 from create_test_sww import create_test_sww 12 12 13 13 sww_name = 'test.sww' … … 16 16 # do export to DEM 17 17 18 sww2dem(sww_name,18 anuga.sww2dem(sww_name, 19 19 name_out='sww2dem_out.asc', 20 quantity=' stage',20 quantity='xmomentum', 21 21 cellsize=0.25, 22 22 easting_min=0, -
trunk/anuga_core/benchmarks/create_test_sww.py
r7810 r7877 9 9 # Setup computational domain 10 10 #------------------------------------------------------------------------------ 11 points, vertices, boundary = anuga.rectangular_cross(5 0, 50,11 points, vertices, boundary = anuga.rectangular_cross(5, 5, 12 12 len1=50.0, len2=50.0) # Mesh 13 13 … … 19 19 #------------------------------------------------------------------------------ 20 20 def topography(x, y): 21 return -x/2 0# linear bed slope21 return -x/2 # linear bed slope 22 22 23 23 domain.set_quantity('elevation', topography) # Use function for elevation -
trunk/anuga_core/documentation/user_manual/demos/cairns/ExportResults.py
r7838 r7877 9 9 10 10 print 'output dir:', name 11 which_var = 411 which_var = 3 12 12 13 13 if which_var == 0: # Stage … … 34 34 35 35 anuga.sww2dem(name+'.sww', 36 outname+'. ers',36 outname+'.asc', 37 37 quantity=quantityname, 38 38 cellsize=100, -
trunk/anuga_core/source/anuga_parallel/parallel_advection.py
r7449 r7877 15 15 from anuga.advection import * 16 16 17 from anuga import Domain 17 18 18 19 import numpy as num -
trunk/anuga_core/source/anuga_parallel/parallel_shallow_water.py
r7449 r7877 12 12 """ 13 13 14 from anuga .interfaceimport Domain14 from anuga import Domain 15 15 16 16 -
trunk/anuga_core/source/anuga_parallel/print_stats.py
r5242 r7877 21 21 import pypar 22 22 23 from Numeric import array, Int8, zeros, ones, take, nonzero, Float23 from numpy import array, zeros, ones, take, nonzero, float 24 24 from anuga.utilities.norms import l1_norm, l2_norm, linf_norm 25 25 -
trunk/anuga_core/source/anuga_parallel/run_parallel_sw_rectangle.py
r7449 r7877 23 23 # Sequential interface 24 24 #--------------------------- 25 from anuga .interfaceimport Domain26 from anuga .interfaceimport Transmissive_boundary, Reflective_boundary25 from anuga import Domain 26 from anuga import Transmissive_boundary, Reflective_boundary 27 27 28 28 #---------------------------- -
trunk/anuga_core/source/anuga_parallel/test_parallel.py
r7519 r7877 6 6 from math import sqrt 7 7 8 9 10 11 12 from anuga.interface import Domain 13 from anuga.interface import rectangular_cross 8 import anuga 14 9 15 10 from anuga_parallel.distribute_mesh import pmesh_divide_metis … … 74 69 if myid == 0: 75 70 76 points, vertices, boundary = rectangular_cross(2,2)77 78 domain = Domain(points, vertices, boundary)71 points, vertices, boundary = anuga.rectangular_cross(2,2) 72 73 domain = anuga.Domain(points, vertices, boundary) 79 74 80 75 -
trunk/anuga_core/source/anuga_parallel/test_parallel_distribute_domain.py
r7562 r7877 25 25 from anuga.utilities.norms import l1_norm, l2_norm, linf_norm 26 26 27 from anuga .interfaceimport Domain28 from anuga .interfaceimport Reflective_boundary29 from anuga .interfaceimport Dirichlet_boundary30 from anuga .interfaceimport Time_boundary31 from anuga .interfaceimport Transmissive_boundary32 33 from anuga .interfaceimport rectangular_cross34 from anuga .interfaceimport create_domain_from_file27 from anuga import Domain 28 from anuga import Reflective_boundary 29 from anuga import Dirichlet_boundary 30 from anuga import Time_boundary 31 from anuga import Transmissive_boundary 32 33 from anuga import rectangular_cross 34 from anuga import create_domain_from_file 35 35 36 36 -
trunk/anuga_validation/automated_validation_tests/flow_tests/test_inflow_using_flowline.py
r7846 r7877 28 28 length = 400. 29 29 width = 20. 30 dx = dy = 1.25# Resolution: of grid on both axes30 dx = dy = 5.0 # Resolution: of grid on both axes 31 31 32 32 points, vertices, boundary = anuga.rectangular_cross(int(length/dx), \ … … 111 111 print domain.volumetric_balance_statistics() 112 112 113 anuga.sww2dem('inflow_flowline_test.sww', 114 name_out='sww2dem_out.asc', 115 quantity='xmomentum', 116 cellsize=0.075, 117 easting_min=0, 118 easting_max=400, 119 northing_min=0, 120 northing_max=20, 121 reduction=max, 122 verbose=True) 123 113 124 114 125 #---------------------------------------------------------------------- … … 143 154 assert num.allclose(domain_depth,normal_depth, rtol=1.0e-2), msg 144 155 156 145 157 146 -
trunk/anuga_validation/convergence_study/dam_break.py
r7846 r7877 76 76 77 77 def height(x,y): 78 z = zeros(len(x), Float)78 z = zeros(len(x), float) 79 79 for i in range(len(x)): 80 80 if x[i]<=50000.0: -
trunk/anuga_work/production/australia_ph2/perth/project.py
r7010 r7877 41 41 starttime=0 # start time for simulation 42 42 finaltime=60000 # final time for simulation 43 setup = ' final_30' # This can be one of three values43 setup = 'trial' # This can be one of three values 44 44 # trial - coarsest mesh, fast 45 45 # basic - coarse mesh … … 186 186 187 187 # create paths generated from environment variables. 188 print os.getenv(ENV_INUNDATIONHOME) 188 189 home = join(os.getenv(ENV_INUNDATIONHOME), 'data') # Absolute path for data folder 189 190 muxhome = os.getenv(ENV_MUXHOME) -
trunk/anuga_work/production/australia_ph2/perth/setup_model.py
r7010 r7877 10 10 11 11 from os.path import join, exists 12 from anuga. utilities.polygon import read_polygon, number_mesh_triangles12 from anuga.geometry.polygon import read_polygon, number_mesh_triangles 13 13 14 14 import project -
trunk/anuga_work/production/new_south_wales/batemans_bay/setup_model.py
r7045 r7877 10 10 11 11 from os.path import join, exists 12 from anuga. utilities.polygon import read_polygon, number_mesh_triangles12 from anuga.geometry.polygon import read_polygon, number_mesh_triangles 13 13 14 14 import project -
trunk/anuga_work/production/tweed_heads/project.py
r7479 r7877 32 32 finaltime=100 # final time for simulation 33 33 34 setup = ' final' # This can be one of three values34 setup = 'trial' # This can be one of three values 35 35 # trial - coarsest mesh, fast 36 36 # basic - coarse mesh … … 143 143 # Environment variable names. 144 144 # The inundation directory, not the data directory. 145 ENV_INUNDATIONHOME = ' INUNDATIONHOME'145 ENV_INUNDATIONHOME = '/home/james/Projects/anuga/anuga_work/production' 146 146 147 147 # Path to MUX data 148 ENV_MUXHOME = ' MUXHOME'148 ENV_MUXHOME = '/home/james/Projects/anuga/anuga_work/production' 149 149 150 150 #------------------------------------------------------------------------------- … … 167 167 168 168 # create paths generated from environment variables. 169 home = join(os.getenv(ENV_INUNDATIONHOME), 'data')# Absolute path for data folder170 muxhome = os.getenv(ENV_MUXHOME)169 home = ENV_INUNDATIONHOME # Absolute path for data folder 170 muxhome = ENV_MUXHOME 171 171 172 172 # check various directories/files that must exist -
trunk/anuga_work/production/tweed_heads/setup_model.py
r7479 r7877 10 10 11 11 from os.path import join, exists 12 from anuga. utilities.polygon import read_polygon, number_mesh_triangles13 from anuga. shallow_water.data_manager importcsv2polygons12 from anuga.geometry.polygon import read_polygon, number_mesh_triangles 13 from anuga.file.csv_file import load_csv_as_polygons as csv2polygons 14 14 import project 15 15
Note: See TracChangeset
for help on using the changeset viewer.