Forum Replies Created
-
AuthorPosts
-
HugoKeymaster
Hi @sayan957
This, I don’t know. But @damien-marchaluniv-lille1-fr should now this for sure.
BestHugo
HugoKeymasterWhen just opening the scene I get this:
[ERROR] [DAGNode(root)] Node.getChild("finger1") not found. [ERROR] [DAGNode(root)] Node.getChild("finger2") not found. [ERROR] [DAGNode(root)] Node.getChild("finger3") not found. [ERROR] [PythonScript] AttributeError: 'NoneType' object has no attribute 'getChild' File "/data/Softwares/sofa/src/plugins/SoftRobots/docs/tutorials/PneunetGripper/details/pythonControllers/wholeGripperController.py", line 37, in initGraph self.pressureConstraint1Node = self.finger1Node.getChild('cavity') [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find edge 0 [0, 502] in triangle 0 [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find edge 0 [0, 502] in triangle 0 [WARNING] [TetrahedronSetTopologyContainer(container)] TrianglesAroundEdge buffer can't be created as EdgesInTriangle buffer creation failed. [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find triangle 1 [89, 393, 635] in tetrahedron 0 [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find triangle 1 [89, 393, 635] in tetrahedron 0 [WARNING] [TetrahedronSetTopologyContainer(container)] TetrahedraAroundTriangle buffer can't be created as trianglesInTetrahedron buffer creation failed. [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find edge 0 [0, 502] in triangle 0 [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find edge 0 [0, 502] in triangle 0 [WARNING] [TetrahedronSetTopologyContainer(container)] TrianglesAroundEdge buffer can't be created as EdgesInTriangle buffer creation failed. [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find triangle 1 [89, 393, 635] in tetrahedron 0 [ERROR] [TetrahedronSetTopologyContainer(container)] Cannot find triangle 1 [89, 393, 635] in tetrahedron 0 [WARNING] [TetrahedronSetTopologyContainer(container)] TetrahedraAroundTriangle buffer can't be created as trianglesInTetrahedron buffer creation failed.
Where are defined these “finger” nodes??
Morevoer, your meshes seem to have issues regarding the error on topology.
I will get back to more basic question.
What do you want to model exactly? how many bodies are involved? what should be their properties?Hugo
HugoKeymasterHey @davidboyd96
I really apologize for the delay of my reply, we’ve been quite busy these last days!
That’s not common the project of yours, using simulation with deep reinforcement learning model sounds super exciting.First thank you, you made yourself very clear.
Unfortunately I have no real experience in using the plastic model which is in SOFA.Elasticity is normal to observe since before becoming plastic the deformation is first elastic. The definition of how quickly we reach the plastic domain should be controlled by the plasticYieldThreshold data.
I will look a bit more in depth, make some screenshots and get back to you.
BestHugo
3 September 2019 at 09:51 in reply to: [SOLVED] Geomagic touch failed to initialize the device #14182HugoKeymasterHi @eyadshak
Your $QT_PLUGIN_PATH and $GTDD_HOME are fine.
However, the $LD_LIBRARY_PATH should also include : /opt/geomagic_touch_device_driver/libCould you try running :
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/geomagic_touch_device_driver/lib
And try again running your simulation?
Hugo
HugoKeymasterHi @eugenekli
Is this how your scene looks like?
I got some issue with STLIB and with your filenames (sensitivity to lower/uppercase).
Next time do not hesitate to share an XML exported version when you are using some many libs and files.Is the result of your simulation a crash directly when you run the simulation?
########## SIG 11 - SIGSEGV: segfault ########## -> /data/Softwares/sofa/build/build-release-master/lib/libSofaHelper.so.19.06.99(sofa::helper::BackTrace::dump()+0x20) [0x7f91010d3b10] -> /data/Softwares/sofa/build/build-release-master/lib/libSofaHelper.so.19.06.99(sofa::helper::BackTrace::sig(int)+0x358) [0x7f91010d40a8] -> /lib/x86_64-linux-gnu/libc.so.6(+0x3ef20) [0x7f90fc165f20] -> /data/Softwares/sofa/src/plugins/SofaPardisoSolver/libPardiso/libpardiso600-GNU720-X86-64.so(METIS_NodeND_ord+0x2d) [0x7f90e00a0f6d] -> /data/Softwares/sofa/src/plugins/SofaPardisoSolver/libPardiso/libpardiso600-GNU720-X86-64.so(METIS_NodeND+0x1c) [0x7f90e00a155c] -> /data/Softwares/sofa/build/build-release-master/lib/libSofaSparseSolver.so(sofa::component::linearsolver::SparseLDLSolverImpl<sofa::component::linearsolver::CompressedRowSparseMatrix<double, sofa::helper::vector<double, sofa::helper::CPUMemoryManager<double> >, sofa::helper::vector<int, sofa::helper::CPUMemoryManager<int> > >, sofa::component::linearsolver::FullVector<double>, sofa::component::linearsolver::NoThreadManager>::LDL_ordering(int, int*, int*, int*, int*)+0x3c2) [0x7f90c5216b12] -> /data/Softwares/sofa/build/build-release-master/lib/libSofaSparseSolver.so(void sofa::component::linearsolver::SparseLDLSolverImpl<sofa::component::linearsolver::CompressedRowSparseMatrix<double, sofa::helper::vector<double, sofa::helper::CPUMemoryManager<double> >, sofa::helper::vector<int, sofa::helper::CPUMemoryManager<int> > >, sofa::component::linearsolver::FullVector<double>, sofa::component::linearsolver::NoThreadManager>::factorize<sofa::helper::vector<int, sofa::helper::CPUMemoryManager<int> >, sofa::helper::vector<double, sofa::helper::CPUMemoryManager<double> > >(int, int*, int*, double*, sofa::component::linearsolver::SparseLDLImplInvertData<sofa::helper::vector<int, ....
Best
Hugo
2 September 2019 at 17:08 in reply to: Activating twoWay option in attachConstraint component or not #14177HugoKeymasterHi @zahra
Thank you @secretdevil for the answer, you are right.As explained in another thread: AttachConstraint is a PairInteraction constraint. It means it couples a pair of objects. It will make sure that the selected nodes (indices1) of object1 follow the associcated nodes (indices2) in object2. If twoWays=false, that’s it:
If twoWays=true, the inverse is true as well: the selected nodes (indices2) of object2 follow the nodes (indices1) of object1. Theh the constraint appears in both object systems:
Cheers
Hugo
HugoKeymasterHi @fleonard
Could you share your scene with us? (link to a github/wetransfer ..)
Since you are imposing the displacement (using the LinearMovementConstraint), the simulation will make sure this constraint is respected even if the object collides with others. Therefore the result is logical and it is working properly.
To work what you expect, a solution to impose the displacement on the rest_position and to add a RestShapeSpringForceField. But it’s hard to give appropriate advices without seeing your simulation.
Best
Hugo
HugoKeymasterHi @jieying
Thank you very much for this interesting question!
Coupling the fields of simulation and computer vision has been investigated and is still active! I will ask the developers in this field to get you an answer and maybe an access to their code. With their work, it should be possible to include in SOFA simulation the cloud point coming from the RGBD camera and then make the comparison. Would this be what you need?I never captured a screenshot from Python, but if you mimic keyboard action : ALT+C it should work.
I’ll get back to you.
HugoHugoKeymasterYes, as you can see from the EulerImplicit code (if it is the OdeSolver, i.e. integration scheme, you are using), the rayleigh stiffness Data is directly used in the code. If you update it, it will be taken into account.
It is really code dependent for the physical parameters (stiffness, i.e. Young modulus).
Which code and which parameters are necessary to update for you?Best
Hugo
2 September 2019 at 16:37 in reply to: [SOLVED] Attach constraint and Fixed constraint difference #14173HugoKeymasterI might have been unclear.
What are your units: mm ? meters ? inches ?
Just make sure that your physical parameters (elasticity, threshold, time steps etc.) are accordingly and properly defined.To more specifically answer the initial question: whas is the difference betweem FixedConstraint and AttachConstraint (with twoWays option):
- FixedConstraint is a projective constraint. It means at each time step, the fixed nodes will a zero-velocity projected. Therefore, they won’t move.
- AttachConstraint is a PairInteraction constraint. It means it couples a pair of objects and it will constraint each of these objects to respect the constraint that x_object1[indices1]=x_object2[indices2]. This constraint is included in the constraint Jacobian matrix H:
Let me know how I can help further.
BestHugo
2 September 2019 at 15:52 in reply to: [SOLVED] Geomagic touch failed to initialize the device #14172HugoKeymasterHi @eyadshak
Sorry for the silence, we’ve been busy. Your echo seems normal.
Can you also test this:echo $GTDD_HOME echo $LD_LIBRARY_PATH
Hugo
HugoKeymasterHi @bobiko
Using the LCPConstraintSolver means that you rely on the Lagrange Multiplier method to solve the constraints using a Gauss Seidel. The lambda (Lagrange Multiplier) resulting from the resolution actually corresponds to the collision forces. But recovering them is a bit tricky. Fasten your seatbelt.
In the MechanicalObject of your object, there is a data field named “constraint”. It should look like:
0 1 55 -0.172748 0.984895 0.0118137 1 1 55 -0.0161293 -0.0148211 0.99976 2 1 55 0.984834 0.172516 0.018446 … 9 2 58 0.487691 -0.305337 0.146266 59 0.333767 -0.208967 0.100102 10 2 58 0.336271 0.407063 -0.271458 59 0.230138 0.278586 -0.185781 11 2 58 0.0393245 0.305838 0.50733 59 0.026913 0.20931 0.347208 …
This constraint field can be octained from the MechanicalObject using:
const MatrixDeriv& constraints = l_mState->read(core::ConstMatrixDerivId::constraintJacobian())->getValue();
This corresponds to: , the matrix containing the constraint directions.
The first digit of each line corresponds to the constraint ID. Therefore one line corresponds to one constraint. Here the data “constraint” has 3 constraints per contact because it corresponds to friction contact.To get the forces, you need to multiply each line (each constraint) with the associated lambda multiplier λ, resulting from the Gauss Seidel resolution. The vector of λ can be obtained from the ConstraintProblem of the simulation, as follows:
sofa::component::constraintset::ConstraintProblem* cp = l_constraintSolver->getConstraintProblem(); sofa::component::linearsolver::FullVector<double> lambdaVector = cp->f;
Let’s compute the force associated to the constraint number 9:
9 2 58 0.487691 -0.305337 0.146266 59 0.333767 -0.208967 0.100102
To make the multiplication, you need to get the ID saved in the column 2 (
constraint[8][1] = 2
here). This digits gives you the number of nodes in the collision mesh are impacted by this constraint. For each node impacted, you have a block corresponding to the node ID and its force in x,y,z [ID fx fy fz].
The constraint number 9 impacts 2 nodes: the node 48 and node 49. To compute the force resulting from the collision applied on each of these node, you need to compute:F_collis[58] += Deriv( 0.487691 -0.305337 0.146266) * lambda[9] F_collis[59] += Deriv( 0.333767 -0.208967 0.100102) * lambda[9]
I hope this is clear enough. If not, I was thinking about creating a specific component to recover the collision forces. I could implement it.
Best wishes,Hugo
HugoKeymasterHi @lakehanne
You are doing well asking about citing SOFA. It is maybe not clear on the website.
All info for citation is given on the Publications page.Best wishes,
Hugo
26 August 2019 at 11:54 in reply to: [SOLVED] Attach constraint and Fixed constraint difference #14158HugoKeymasterI mean, what should be the size the square object, what should be its Young modulus ?
HugoKeymasterHi @gaetan
We are not forgetting you! Sorry for the delay.
@jnbrunet apparently you are also on Fedora. Could you have a look to @gaetan ‘s error when you have a bit of time please? @guillaumeparan is also on it.Best
Hugo
HugoKeymasterFor sure you can update to 19.06, you should have better experience with other masses than UniformMass. I worked few months ago in making the Diagonal and MeshMatrixMass able to be updated.
However, you will still face the issue with the ForceFields. It would require a bit of work to make them updatable. Maybe start with the update and we can work together on the update of the other components. How does it sound for you?Hugo
HugoKeymasterI am getting the following error by trying your scene:
[ERROR] [PythonScript] TypeError: 'staticmethod' object is not callable File "BellowArm.pyscn", line 94, in createScene bellow1 = Bellow(rootNode,[35,0,20]) File "BellowArm.pyscn", line 42, in Bellow collisionMesh =stlPath) File "/data/Softwares/sofa/src/plugins/STLIB/python/splib/objectmodel/__init__.py", line 47, in __call__ o = self.cls(*args, **kwargs) File "/data/Softwares/sofa/src/plugins/STLIB/python/stlib/physics/deformable/elasticmaterialobject.py", line 30, in __init__ collisionMesh, withConstrain, surfaceColor, poissonRatio, youngModulus, totalMass, solver)
Does this remind you an error you faced?
Hugo
23 August 2019 at 11:55 in reply to: [SOLVED] Attach constraint and Fixed constraint difference #14147HugoKeymasterHugoKeymasterHi @eugenekli
It seems meshes (stl/vtk) are missing, I got path issues and so on.
Could you please make a simple example based on SOFA classes that exposes your problem? or sharing your meshes would be required.Hugo
HugoKeymasterHey @bobiko
Did you finally used my patch?
If yes, could you pull request this change? It would be interesting that other developers see and benefit from it.Thanks!
Hugo
HugoKeymasterHi @lakehanne
The SOFA community is made of SMEs, companies, universities and research centers. Job offers posted online are onsite positions for now. I guess it might depend on the institution. The only engineers working remotely are independent developers.
However, do not hesitate to contact any institution if one is of interest to ask about such remote position.Best
Hugo
HugoKeymasterHugoKeymasterHi @aforuzan
I am not sure about what you want to do with the CMakeLists. You want to compile the oneParticle project ?
If so, you can go in your build/ repository of SOFA, run cmake-gui and make sure the option TUTORIAL_ONE_PARTICLE is activated.Best
Hugo
HugoKeymasterHi @ma1991
Ok, it is a really challenging objective.
Regarding the mesh, you need to make each thread is well independent from the other. I would even go for modeling each thread separately.But regarding the complexity of your problem, this needs to be discussed more in depth and a forum thread is maybe not the best option. Do you have any expert in numerical analysis and modeling in your team? This is the profile you need here.
Hugo
HugoKeymasterDear @aforuzan
Thank you for your interest in SOFA and welcome on the open forum!
There is “Hello World” C++ example in SOFA, but there is some rather simple codes though.
You can for instance find in applications/tutorials/ (like the oneParticle.cpp)To check if SOFA successfully compiled, you can simply run the generated executable “runSofa” (in your build/bin repository)
Best,
Hugo
-
AuthorPosts