Page MenuHomec4science

tamaas.py
No OneTemporary

File Metadata

Created
Wed, Nov 6, 17:05

tamaas.py

try:
from ._tamaas import *
# Redefinition of model_type constants (for compatibility)
model_type_basic_1d = model_type.basic_1d
model_type_basic_2d = model_type.basic_2d
model_type_surface_1d = model_type.surface_1d
model_type_surface_2d = model_type.surface_2d
model_type_volume_1d = model_type.volume_1d
model_type_volume_2d = model_type.volume_2d
except ImportError:
print("Could not find _tamaas.<cpython-version>.so")
class ParamHelper:
def __init__(self, obj):
self.obj = obj
def set(self, params):
for key in params:
setter_name = 'set' + key
try:
accessor = getattr(self.obj, setter_name)
accessor(params[key])
except:
print("Setter '{}({})' does not exist for object {}".format(setter_name,
type(params[key]),
self.obj))

Event Timeline