source: branches/numpy/contributed_code/tools/r2d/Convert_Csv_Pts2NetCDF_DEM.py @ 7244

Last change on this file since 7244 was 5780, checked in by ole, 16 years ago

Added contributed code from Petar Milevski

File size: 650 bytes
Line 
1""" Converts Points Data in csv format to NETCDF DEM
2for use in Anuga 2D model
3
4"""
5
6
7import os
8import time
9import sys
10from anuga.geospatial_data.geospatial_data import Geospatial_data
11
12basename = 'csv' #input file name
13elevation_file = 'csv' #input file name
14meshname = 'csv.msh' 
15
16# Create pts file
17print 'Reading and Converting', elevation_file
18print '... This might take a minute or so depending on file size.....'
19print '... STILL WORKING....' 
20G = Geospatial_data(elevation_file+'.csv')
21G.export_points_file(basename+'.pts')
22print 'Creating', meshname
23
24print 'New Files Created OK:'
25key= raw_input('Hit Any Key to End') 
Note: See TracBrowser for help on using the repository browser.