- Timestamp:
- Sep 8, 2008, 3:55:57 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/source/anuga/shallow_water/test_data_manager.py
r5734 r5745 6822 6822 elevation = fid.variables['elevation'][:] 6823 6823 time=fid.variables['time'][:]+fid.starttime 6824 6825 6826 # Check that stored permutation is as per default 6827 permutation = range(len(x)) 6828 stored_permutation = fid.variables['permutation'][:] 6829 msg = 'Permutation was not stored correctly. I got ' 6830 msg += str(stored_permutation) 6831 assert allclose(stored_permutation, permutation), msg 6824 6832 6825 6833 # get quantity data from sts file … … 7020 7028 # Note, the sts info is not gridded. It is point data. 7021 7029 fid = NetCDFFile(sts_file) 7030 7031 # Check that original indices have been stored 7032 stored_permutation = fid.variables['permutation'][:] 7033 msg = 'Permutation was not stored correctly. I got ' 7034 msg += str(stored_permutation) 7035 assert allclose(stored_permutation, permutation), msg 7036 7022 7037 7023 7038 # Make x and y absolute … … 7359 7374 7360 7375 #------------------------------------------------------------ 7361 # Now read the mux files one by one with 7376 # Now read the mux files one by one without weights and test 7362 7377 7363 7378 # Call urs2sts with mux file #0 … … 7372 7387 fid = NetCDFFile(sts_file) 7373 7388 7389 # Check that original indices have been stored 7390 stored_permutation = fid.variables['permutation'][:] 7391 msg = 'Permutation was not stored correctly. I got ' 7392 msg += str(stored_permutation) 7393 assert allclose(stored_permutation, permutation), msg 7394 7395 7396 7397 7374 7398 # Make x and y absolute 7375 7399 x = fid.variables['x'][:] … … 7476 7500 sts_file = base_nameI + '.sts' 7477 7501 fid = NetCDFFile(sts_file) 7478 7502 7503 # Check that original indices have been stored 7504 stored_permutation = fid.variables['permutation'][:] 7505 msg = 'Permutation was not stored correctly. I got ' 7506 msg += str(stored_permutation) 7507 assert allclose(stored_permutation, permutation), msg 7508 7479 7509 # Make x and y absolute 7480 7510 x = fid.variables['x'][:]
Note: See TracChangeset
for help on using the changeset viewer.