Index: /production/pt_hedland_2006/project.py
===================================================================
--- /production/pt_hedland_2006/project.py	(revision 3271)
+++ /production/pt_hedland_2006/project.py	(revision 3272)
@@ -47,5 +47,4 @@
     home = getenv('INUNDATIONHOME', sep+'d'+sep+'cit'+sep+'2'+sep+'cit'+sep+'inundation'+sep+'data')     
     user = getenv('LOGNAME')
-    print 'USER:', user
 
 #Derive subdirectories and filenames
Index: /production/pt_hedland_2006/run_pt_hedland.py
===================================================================
--- /production/pt_hedland_2006/run_pt_hedland.py	(revision 3271)
+++ /production/pt_hedland_2006/run_pt_hedland.py	(revision 3272)
@@ -33,4 +33,24 @@
 import project                 # Definition of file names and polygons
 
+#-------------------------------------------------------------------------------
+# Copy scripts to time stamped output directory and capture screen
+# output to file
+#-------------------------------------------------------------------------------
+
+# creates copy of code in output dir if dir doesn't exist
+if access(project.outputtimedir,F_OK) == 0 :
+    mkdir (project.outputtimedir)
+copy (dirname(project.__file__) +sep+ project.__name__+'.py', project.outputtimedir + project.__name__+'.py')
+copy (__file__, project.outputtimedir + basename(__file__))
+print 'project.outputtimedir',project.outputtimedir
+
+# normal screen output is stored in 
+screen_output_name = project.outputtimedir + "screen_output.txt"
+screen_error_name = project.outputtimedir + "screen_error.txt"
+
+# used to catch screen output to file
+sys.stdout = Screen_Catcher(screen_output_name)
+sys.stderr = Screen_Catcher(screen_error_name)
+print 'USER:    ', project.user
 
 #-------------------------------------------------------------------------------
@@ -48,20 +68,4 @@
 meshname = project.meshname+'.msh'
 source_dir = project.boundarydir
-
-## creates copy of code in output dir if dir doesn't exist
-if access(project.outputtimedir,F_OK) == 0 :
-    mkdir (project.outputtimedir)
-copy (dirname(project.__file__) +sep+ project.__name__+'.py', project.outputtimedir + project.__name__+'.py')
-copy (__file__, project.outputtimedir + basename(__file__))
-
-print 'project.outputtimedir',project.outputtimedir
-
-##normal screen output is stored in 
-screen_output_name = project.outputtimedir + "screen_output.txt"
-screen_error_name = project.outputtimedir + "screen_error.txt"
-
-#used to catch screen output to file
-sys.stdout = Screen_Catcher(screen_output_name)
-sys.stderr = Screen_Catcher(screen_error_name)
 
 # fine data (clipping the points file to smaller area)
@@ -80,17 +84,12 @@
 print 'create G1'
 G1 = Geospatial_data(file_name = project.offshore_dem_name1 + '.xya')
-
 print 'create G2'
 G2 = Geospatial_data(file_name = project.offshore_dem_name2 + '.xya')
-
 print 'create G3'
 G3 = Geospatial_data(file_name = project.onshore_dem_name + '.pts')
-
 print 'add G1+G2+G3'
 G = G1 + G2 + G3
-
 print 'export G'
 G.export_points_file(project.combined_dem_name + '.pts')
-
 
 #-------------------------------------------------------------------------------                                 
@@ -105,6 +104,4 @@
 coast_res = 25000
 pt_hedland_res = 5000
-# derive poly_coast from project.coast_name using alpha_shape
-#interior_regions = [[project.poly_pt_hedland, pt_hedland_res],
 interior_regions = [[project.poly_pt_hedland, pt_hedland_res],
                     [project.poly_region, region_res]]
@@ -112,16 +109,5 @@
 print 'number of interior regions', len(interior_regions)
 
-from utilities.polygon import inside_polygon, plot_polygons
-
-bounding_polygon = project.polyAll
-count = 0
-for i in range(len(interior_regions)):
-    region = interior_regions[i]
-    interior_polygon = region[0]
-    if len(inside_polygon(interior_polygon, bounding_polygon,
-                   closed = True, verbose = False)) <> len(interior_polygon):
-        print 'WARNING: interior polygon %d is outside bounding polygon' %(i)
-        count += 1
-
+from utilities.polygon import plot_polygons
 if sys.platform == 'win32':
     #figname = project.outputtimedir + 'pt_hedland_polys'
@@ -131,27 +117,15 @@
               verbose = True)    
 
-if count == 0:
-    print 'interior regions OK'
-else:
-    print 'check out your interior polygons'
-    print 'check %s in production directory' %figname
-    import sys; sys.exit()
-    
 print 'start create mesh from regions'
 from caching import cache
 _ = cache(create_mesh_from_regions,
           project.polyAll,
-#          project.poly_region,
-#          {'boundary_tags': {'right': [0], 'bottomright': [1],
-#                             'bottomleft': [2], 'left': [3], 'top': [4]},
-#          {'boundary_tags': {'topright': [0], 'top': [1],'topleft': [2], 'left': [3],
-#                             'bottomleft': [4], 'bottomright': [5], 'right': [6]},
-          {'boundary_tags': {'topright': [0],'topleft': [1], 'left': [2],
-                             'bottomleft': [3], 'bottomright': [4], 'right': [5]},
+          {'boundary_tags': {'topright': [0], 'topleft': [1],
+                             'left': [2], 'bottomleft': [3],
+                             'bottomright': [4], 'right': [5]},
            'maximum_triangle_area': 500000,
            'filename': meshname,           
            'interior_regions': interior_regions},
           verbose = True, evaluate=True)
-
 
 #-------------------------------------------------------------------------------                                 
@@ -206,5 +180,5 @@
 cache(ferret2sww,
       (source_dir + project.boundary_basename,
-       source_dir + project.boundary_basename), 
+       source_dir + project.boundary_basename+'_'+project.basename), 
       {'verbose': True,
        'minlat': south,
@@ -219,6 +193,6 @@
        'inverted_bathymetry': True},
        evaluate = True,
-       verbose = True,)
-
+       verbose = True,
+      dependencies = source_dir + project.boundary_basename + '.sww')
 
 print 'Available boundary tags', domain.get_boundary_tags()
@@ -228,8 +202,6 @@
 Br = Reflective_boundary(domain)
 Bd = Dirichlet_boundary([tide,0,0])
-
 domain.set_boundary( {'topright': Bf,'topleft': Bf, 'left':  Bd,
-                             'bottomleft': Bd, 'bottomright': Bd, 'right': Bd})
-                             
+                      'bottomleft': Bd, 'bottomright': Bd, 'right': Bd})
 #-------------------------------------------------------------------------------                                 
 # Evolve system through time
