Changeset 21171


Ignore:
Timestamp:
08/26/16 14:45:14 (9 years ago)
Author:
Mathieu Morlighem
Message:

CHG: better error message

Location:
issm/trunk-jpl/src/m/mesh
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/m/mesh/triangle.m

    r19949 r21171  
    3636
    3737area=resolution^2;
     38
     39%Check that file exist (this is a very very common mistake)
     40if ~exist(domainname)
     41        error(['file "' domainname '" not found']);
     42end
    3843
    3944%Mesh using TriMesh
  • issm/trunk-jpl/src/m/mesh/triangle.py

    r20910 r21171  
    4343        area = resolution**2
    4444
     45        #Check that file exist (this is a very very common mistake)
     46        if not os.path.exists(domainfile):
     47                raise IOError("file '%s' not found" % domainfile)
     48
    4549        #Mesh using TriMesh
    4650        md.mesh=mesh2d()
Note: See TracChangeset for help on using the changeset viewer.