Changeset 10148


Ignore:
Timestamp:
10/08/11 17:00:14 (13 years ago)
Author:
Mathieu Morlighem
Message:

improved python interface (slightly)

Location:
issm/trunk
Files:
1 added
1 deleted
4 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk/src/py/classes/model.py

    r10119 r10148  
     1from mesh import *
     2
    13class model:
    24        """Python model class"""
    3         x = []
    4         y = []
    5         elements = []
     5        mesh=mesh()
    66        def __init__(self):
    77                print 'new model created'
     8        def __repr__(self):
     9                return "   mesh: mesh properties"
  • issm/trunk/src/py/modules/TriMesh/Makefile

    r10119 r10148  
    1 all:
     1all: ogive
     2
     3ice:
    24        g++ -bundle  -bind \
    35                -I$(ISSM_TIER)/externalpackages/boost/install/include \
     
    57                -L/usr/lib/python2.6/config/ -lpython2.6 \
    68                TriMeshmodule.cpp -o TriMesh.so
    7         #-I/usr/include/python2.6/ \
     9
     10ogive:
     11        g++ \
     12                -I$(ISSM_TIER)/externalpackages/boost/install/include \
     13                -I/opt/local/include/python2.5/ \
     14                -L$(ISSM_TIER)/externalpackages/boost/install/lib -lboost_python \
     15                -L/usr/lib/ -lpython2.5 \
     16                TriMeshmodule.cpp -o TriMesh.so -bundle
     17
     18clean:
     19        rm TriMesh.so
  • issm/trunk/src/py/modules/hello/Makefile

    r10119 r10148  
    1 all:
     1all: ogive
     2
     3ice:
    24        g++ -bundle  -bind \
    35                -I$(ISSM_TIER)/externalpackages/boost/install/include \
     
    68                -L/usr/lib/python2.6/config/ -lpython2.6 \
    79                hellomodule.cpp -o hello.so
     10
     11ogive:
     12        g++ \
     13                -I$(ISSM_TIER)/externalpackages/boost/install/include \
     14                -I/usr/include/python2.5/ \
     15                -L$(ISSM_TIER)/externalpackages/boost/install/lib -lboost_python \
     16                -L/usr/lib/python2.5/config/ -lpython2.5 \
     17                hellomodule.cpp -o hello.so -bundle
     18
     19clean:
     20        rm hello.so
  • issm/trunk/startup.py

    r10119 r10148  
    2222sys.path.append(ISSM_TIER+'/src/py')
    2323sys.path.append(ISSM_TIER+'/src/py/classes')
    24 import model
     24sys.path.append(ISSM_TIER+'/src/py/modules/TriMesh')
     25sys.path.append(ISSM_TIER+'/src/py/modules/hello')
     26from model import *
    2527
    2628print "\n  To get started with ISSM, type issmdoc at the command prompt.\n\n"
Note: See TracChangeset for help on using the changeset viewer.