Ignore:
Timestamp:
Jan 9, 2009, 3:03:09 PM (16 years ago)
Author:
ole
Message:

Added polygon values example file

File:
1 edited

Legend:

Unmodified
Added
Removed
  • anuga_core/source/anuga/shallow_water/data_manager.py

    r6120 r6130  
    67606760    # try to open!
    67616761    try:
    6762         fid = open(file, "r")
     6762        fid = open(file, 'r')
    67636763        file_header = fid.readline()
    67646764        fid.close()
    67656765        if verbose: print 'read file header %s' % file_header
    67666766    except:
    6767         msg = 'try to create new file', file
     6767        msg = 'try to create new file: %s' % file
    67686768        if verbose: print msg
    67696769        #tries to open file, maybe directory is bad
    67706770        try:
    6771             fid = open(file, "w")
     6771            fid = open(file, 'w')
    67726772            fid.write(header)
    67736773            fid.close()
    67746774            file_header=header
    67756775        except:
    6776             msg = 'cannot create new file', file
    6777             raise msg
     6776            msg = 'cannot create new file: %s' % file
     6777            raise Exception, msg
    67786778
    67796779    # if header is same or this is a new file
    67806780    if file_header == str(header):
    6781         fid = open(file, "a")
     6781        fid = open(file, 'a')
    67826782        fid.write(line)
    67836783        fid.close()
     
    67876787        # end of details_temp.cvs file in output directory
    67886788        file = str(kwargs['output_dir']) + 'detail_temp.csv'
    6789         fid = open(file, "a")
     6789        fid = open(file, 'a')
    67906790        fid.write(header)
    67916791        fid.write(line)
Note: See TracChangeset for help on using the changeset viewer.