Changeset 4526
- Timestamp:
- Jun 1, 2007, 4:39:17 PM (18 years ago)
- Location:
- anuga_core/source/anuga
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/source/anuga/damage_modelling/inundation_damage.py
r4504 r4526 140 140 dir_ls = os.listdir(dir) 141 141 interate_over = [x for x in dir_ls if base in x and x[-4:] == '.sww'] 142 if len(interate_over) == 0: 143 msg = 'No files of the base name %s.'\ 144 %(sww_base_name) 145 raise IOError, msg 142 146 #print "interate_over", interate_over 143 147 from os import sep -
anuga_core/source/anuga/shallow_water/data_manager.py
r4524 r4526 1649 1649 #print "base",base 1650 1650 1651 if dir == "": dir = "." # Unix compatibility 1651 if dir == "": 1652 dir = "." # Unix compatibility 1652 1653 dir_ls = os.listdir(dir) 1653 1654 interate_over = [x[:-4] for x in dir_ls if base in x and x[-4:] == '.sww'] 1654 #print "interate_over", interate_over 1655 1656 if len(interate_over) == 0: 1657 msg = 'No files of the base name %s.'\ 1658 %(basename_in) 1659 raise IOError, msg 1655 1660 1656 1661 files_out = [] -
anuga_core/source/anuga/shallow_water/test_data_manager.py
r4520 r4526 1633 1633 os.remove(ascfile) 1634 1634 os.remove(swwfile) 1635 1636 def test_export_grid_bad(self): 1637 """Test that sww information can be converted correctly to asc/prj 1638 format readable by e.g. ArcView 1639 """ 1640 1641 try: 1642 export_grid('a_small_round-egg', 1643 quantities = ['elevation', 'depth'], 1644 cellsize = 99, 1645 verbose = self.verbose, 1646 format = 'asc') 1647 except IOError: 1648 pass 1649 else: 1650 self.failUnless(0 ==1, 'Bad input did not throw exception error!') 1635 1651 1636 1652 def test_export_grid_parallel(self):
Note: See TracChangeset
for help on using the changeset viewer.