Ejemplo n.º 1
0
class Amelet(IsModel):
    AMELETHDF_FORMAT_VERSION = String("1.0.0")
    FORMAT = String('AMELETHDF')
    
    entryPoint = PathWhere(EntryPointIndex)
    
    floatingType = Dict(UserName, Instance(FloatingType))
    simulation = Dict(UserName, Instance(Simulation))
    mesh = Dict(UserName, Instance(MeshGroup))
Ejemplo n.º 2
0
class SMesh(Mesh):
    type = String('structured')

    cartesianGrid = Instance(CartesianGrid)

    group = Dict(UserName, Instance(SGroup))
    groupGroup = Dict(UserName, Instance(SGroupGroup))
Ejemplo n.º 3
0
class ConstContainer(IsModel):
    """model class with constants  
    """
    i = Int(1)
    f = Float(1.0)
    b = Bool(True)
    c = Complex(complex(0.1, 0.1))
    s = String('string')
Ejemplo n.º 4
0
class UMesh(Mesh):
    type = String('unstructured')

    nodes = Array(shape=(None, None), dtype=ah5_float)
    elementTypes = Array(shape=(None, ), dtype=ah5_int)
    elementNodes = Array(Shape=(None, ), dtype=ah5_int)

    group = Dict(UserName, Instance(UGroup))
    groupGroup = Dict(UserName, Instance(UGroupGroup))
Ejemplo n.º 5
0
class ComplexContainer(IsModel):
    """genetic model class 
    """
    const = String('MODEL')

    # data set
    array = Array

    #
    subContainer = Instance(SimpleContainer)

    #
    list_of = Dict(UserName, Instance(ConstContainer))
    #
    list_indexed = List(Instance(AA))

    #
    table_t = List(Tuple(Instance(String), Instance(Int)))
Ejemplo n.º 6
0
class Interval(FloatingType):
    floatingType = String("LinearListOfReal1")
    first = Float
    last = Float
Ejemplo n.º 7
0
class LinearListOfInteger2(FloatingType):
    floatingType = String("linearListOfInteger2")
    first = Float
    step = Float
    number_of_values = Int
Ejemplo n.º 8
0
class PerDecadeListOfReal(FloatingType):
    floatingType = String("perDecadeListOfReal")
    first = Float
    number_of_decades = Int
    number_of_values_per_decade = Int
Ejemplo n.º 9
0
class LogarithmListOfReal(FloatingType):
    floatingType = String("logarithmListOfReal")
    first = Float
    last = Float
    number_of_values = Int
Ejemplo n.º 10
0
class LinearListOfReal1(FloatingType):
    floatingType = String("linearListOfReal1")
    first = Float
    last = Float
    number_of_values = Int
Ejemplo n.º 11
0
class DataSet(FloatingType):
    floatingtype = String('dataset')
    values = Array
Ejemplo n.º 12
0
class SingleReal(FloatingType):
    floatingType = String('singleReal')
    value = Float

    def __float__(self):
        return self.value
Ejemplo n.º 13
0
class AAB(AA):
    """second model sub-class
    """
    c = String('b')
Ejemplo n.º 14
0
class AAA(AA):
    """first model sub-class  
    """
    c = String('a')
Ejemplo n.º 15
0
class SingleComplex(FloatingType):
    floatingType = String('singleComplex')
    value = Complex

    def __complex__(self):
        return self.value
Ejemplo n.º 16
0
class SingleInterger(FloatingType):
    floatingType = String('singleInteger')
    value = Int

    def __int__(self):
        return self.value
Ejemplo n.º 17
0
class ArraySet(FloatingType):
    flatingtype = String('arrayset')

    data = Array
    ds = Dict(String(regex='dim[0-9]+'), Array(shape=(None, )))
Ejemplo n.º 18
0
class SingleString(FloatingType):
    floatingType = String('singleString')
    value = String

    def __str__(self):
        return self.value
Ejemplo n.º 19
0
class Vector(FloatingType):
    floatingType = String("vector")
    values = Array()