Compute meshes on cluster.
Greetings,
I have some difficulty perfoming task of remote meshes computation using JobManager.
Main idea behind the project is to use salome for meshing while importing geometries from other sources.
After some research i was able to run mesh computation on the cluster via JobManager using python study dump, this way I need to attach all imported geometry files, on the over hand hdf study file contains them so i need only study file itself to perform computation.
The problem is if i perform computation running python script which loads study i am able to recieve SALOMEDS(mesh in particular) object by its ID i cant recieve its IOR so i am unable to recieve corba object associated with it. Localy though everything goes fine.
Simplified computation script is in attachment.
There are some unnecessary imports in this script cuz it is based on the python study dump.
Solved.
import salome
salome.salome_init()
theStudy = salome.myStudyManager.Open("Study.hdf")
import smesh
from salome.smesh import smeshstudytools
SMSTools = smeshstudytools.SMeshStudyTools()
SMSTools.updateStudy(theStudy._get_StudyId())
sobject = theStudy.FindObjectID("0:1:2:3")
if sobject:
object = SMSTools.getObjectFromSObject(sobject)
mesh = smesh.Mesh(object)
mesh.Compute()
I am not sure this is the right way to do things but this thing does the trick.
