simphony / simphony-mayavi

The mayavi adapters to the simphony framework
BSD 2-Clause "Simplified" License
0 stars 1 forks source link

Running mesh_example.py produces error using common 0.3.1.dev0 #189

Open khiltunen opened 7 years ago

khiltunen commented 7 years ago

Running from simphony-mayavi/examples python mesh_example.py produces error

/usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/core/cuds_item.py:7: UserWarning: Deprecation warning: CUDSItem is deprecated. Use CUBA instead. .format('CUDSItem is deprecated. Use CUBA instead.')) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: add_points warnings.warn("Deprecation warning: {}".format(func.name)) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: add_edges warnings.warn("Deprecation warning: {}".format(func.name)) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: add_faces warnings.warn("Deprecation warning: {}".format(func.name)) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: add_cells warnings.warn("Deprecation warning: {}".format(func.name)) Xlib: extension "RANDR" missing on display "localhost:11.0". /usr/local/lib/python2.7/dist-packages/traits-4.7.0.dev2-py2.7-linux-x86_64.egg/traits/etsconfig/etsconfig.py:429: UserWarning: Environment variable "HOME" not set, setting home directory to /tmp (environment_variable, parent_directory)) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/io/data_container_description.py:63: UserWarning: Some keywords are not supported for serialisation: ATOM, ATOMISTIC, BASE_CENTERED_MONOCLINIC_LATTICE, BASE_CENTERED_ORTHORHOMBIC_LATTICE, BASIS, BERENDSEN, BINGHAM_PLASTIC_MODEL, BIRD_CARREAU_MODEL, BODY_CENTERED_CUBIC_LATTICE, BODY_CENTERED_ORTHORHOMBIC_LATTICE, BODY_CENTERED_TETRAGONAL_LATTICE, BOND, BOUNDARY, BOX, BRAVAIS_LATTICE, CELL, CFD, COMPRESSIBILITY_MODEL, COMPUTATIONAL_METHOD, COMPUTATIONAL_MODEL, CONDITION, CONSTANT_ELECTROSTATIC_FIELD_MODEL, CONTINUUM, COULOMB, COULOMB_FRICTION_FORCE, CROSS_POWER_LAW_MODEL, CUBIC_LATTICE, CUDS_COMPONENT, CUDS_ITEM, DATA_SET, DEM, DIRICHLET, DISSIPATION_FORCE, EDGE, ELECTRONIC, ELECTROSTATIC_MODEL, EMPTY, ENGINE, ENGINE_FEATURE, FACE, FACE_CENTERED_CUBIC_LATTICE, FACE_CENTERED_ORTHORHOMBIC_LATTICE, FEM, FREE, FREE_SURFACE_MODEL, FVM, GRANULAR_DYNAMICS, GRAVITY_MODEL, HERSCHEL_BULKLEY_MODEL, HEXAGONAL_LATTICE, INCOMPRESSIBLE_FLUID_MODEL, INLET_OUTLET, INTEGRATION_STEP, INTEGRATION_TIME, INTERATOMIC_POTENTIAL, ISOTHERMAL_MODEL, KS_DFT, LAMINAR_FLOW_MODEL, LATTICE, LENNARD_JONES_6_12, MATERIAL, MATERIAL_RELATION, MESH, MESH_ELEMENT, MESOSCOPIC, MESO_SCOPIC_RELATIVE_VELOCITY_MODEL, MESO_SCOPIC_STRESS_MODEL, MIXTURE_MODEL, MODEL_EQUATION, MOLECULAR_DYNAMICS, MOLECULAR_STATICS, MONOCLINIC_LATTICE, MULTIPHASE_MODEL, NEUMANN, NEWTONIAN_FLUID_MODEL, NODE, NOSE_HOOVER, ORIGIN, ORTHORHOMBIC_LATTICE, PAIR_POTENTIAL, PARTICLE, PARTICLES, PERIODIC, PHYSICS_EQUATION, POINT, POWER_LAW_VISCOSITY_MODEL, PRIMITIVE_CELL, RELATIVE_VELOCITY_MODEL, RHEOLOGY_MODEL, RHOMBOHEDRAL_LATTICE, SHEAR_STRESS_POWER_LAW_SLIP_VELOCITY, SIMPLE_RELATIVE_VELOCITY_MODEL, SINGLE_PHASE_MODEL, SJKR_COHESION_FORCE, SLIP_VELOCITY, SOFTWARE_TOOL, SOLVER_PARAMETER, SPH, STANDARD_STRESS_MODEL, STRESS_MODEL, SURFACE_TENSION_RELATION, TEMPERATURE_RESCALING, TETRAGONAL_LATTICE, THERMAL_MODEL, THERMOSTAT, TRICLINIC_LATTICE, TURBULENCE_MODEL, VERLET, VERSION, WETTING_ANGLE ', '.join(ignored_keys))) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: iter_points warnings.warn("Deprecation warning: {}".format(func.name)) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: iter_edges warnings.warn("Deprecation warning: {}".format(func.name)) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: iter_faces warnings.warn("Deprecation warning: {}".format(func.name)) /usr/local/lib/python2.7/dist-packages/simphony-0.3.1.dev0-py2.7.egg/simphony/cuds/utils.py:8: UserWarning: Deprecation warning: iter_cells warnings.warn("Deprecation warning: {}".format(func.name)) Traceback (most recent call last): File "mesh_example.py", line 47, in mayavi_tools.show(mesh) File "/usr/local/lib/python2.7/dist-packages/simphony_mayavi-0.5.0.dev38-py2.7.egg/simphony_mayavi/show.py", line 22, in show source = CUDSSource(cuds=cuds) File "/usr/local/lib/python2.7/dist-packages/simphony_mayavi-0.5.0.dev38-py2.7.egg/simphony_mayavi/sources/cuds_source.py", line 136, in init self.cuds = cuds File "/usr/local/lib/python2.7/dist-packages/simphony_mayavi-0.5.0.dev38-py2.7.egg/simphony_mayavi/sources/cuds_source.py", line 73, in _set_cuds self._update_vtk_cuds_from_cuds(value) File "/usr/local/lib/python2.7/dist-packages/simphony_mayavi-0.5.0.dev38-py2.7.egg/simphony_mayavi/sources/cuds_source.py", line 206, in _update_vtk_cuds_from_cuds vtk_cuds = VTKMesh.from_mesh(cuds) File "/usr/local/lib/python2.7/dist-packages/simphony_mayavi-0.5.0.dev38-py2.7.egg/simphony_mayavi/cuds/vtk_mesh.py", line 174, in from_mesh mappings=mappings) TypeError: Can't instantiate abstract class VTKMesh with abstract methods _add_cells, _add_edges, _add_faces, _add_points, _get_cell, _get_edge, _get_face, _get_point, _has_cells, _has_edges, _has_faces, _has_points, _iter_cells, _iter_edges, _iter_faces, _iter_points, _update_cells, _update_edges, _update_faces, _update_points

stefanoborini commented 7 years ago

It's still not ported to the simphony-common master.

stefanoborini commented 7 years ago

I was actually in progress on that, but other issues prevented me to continue.