Closed alxbilger closed 1 year ago
[ci-build][with-all-tests]
[ci-build][with-all-tests]
[ci-build]
Unit tests added! Performances using the benchmark scenes seem similar to the current ones. To be reviewed @sofa-framework/reviewers
[ci-build][with-all-tests]
Using the PR on penalities contact response works!!!
:point_down:
Excellent ! Just make sure that you have an assembled matrix in the scene. Thanks for the feedback
I tried with some scenes with BeamAdapter and there are crashes & stuff 😬
AdaptiveBeamForceFieldAndMass<DataTypes>::addForce
too when trying SingleBeamDeployment.scn
.
I am suspecting there are some problems with size/resize/topologyChange because SingleBeam.scn works well (I think 😅)scenes/3instruments_collis.scn
has a problem with AdvancedTimer, while trying to find an id in the idmap. I am suspecting a corruption going somewhere else but no idea where.[ci-build][full-build][with-all-tests]
@fredroy Thanks a lot for the tests. I'll investigate
@fredroy I think all the problems you found are only due to RestShapeSpringForceField. I am now able to run (properly I think) both scenes SingleBeamDeployment.scn and 3instruments_collis.scn. Could you confirm that?
@fredroy I think all the problems you found are only due to RestShapeSpringForceField. I am now able to run (properly I think) both scenes SingleBeamDeployment.scn and 3instruments_collis.scn. Could you confirm that?
Good news, it works well !
And a bad news but not directly related to your PR, if parallelCollisionDetectionAndFreeMotion
is activated for the animationloop in scenes/3instruments_collis.scn
, there is a crash on the message mechanism. Here is the backtrace:
[Inline Frame] Sofa.Helper.dll!std::_Check_C_return(int _Res) Line 131 C++
[Inline Frame] Sofa.Helper.dll!std::_Mutex_base::lock() Line 50 C++
[Inline Frame] Sofa.Helper.dll!std::lock_guard<std::mutex>::{ctor}(std::mutex & _Mtx) Line 427 C++
Sofa.Helper.dll!sofa::helper::logging::MessageDispatcher::process(sofa::helper::logging::Message & m) Line 151 C++
Sofa.Helper.dll!sofa::helper::logging::MessageDispatcher::LoggerStream::~LoggerStream() Line 198 C++
Sofa.GUI.Qt.dll!redirectQtMessages(QtMsgType type, const QMessageLogContext & context, const QString & msg) Line 40 C++
[External Code]
Sofa.GUI.Qt.dll!sofa::gui::qt::setMessageIconFrom(QTreeWidgetItem * item, sofa::core::objectmodel::Base * object) Line 325 C++
Sofa.GUI.Qt.dll!sofa::gui::qt::ObjectStateListener::notifyEndEdit() Line 350 C++
Sofa.Core.dll!sofa::core::objectmodel::DDGNode::notifyEndEdit() Line 83 C++
[Inline Frame] Sofa.Helper.dll!sofa::helper::logging::MessageDispatcherImpl::process(sofa::helper::logging::Message &) Line 119 C++
Sofa.Helper.dll!sofa::helper::logging::MessageDispatcher::process(sofa::helper::logging::Message & m) Line 152 C++
Sofa.Helper.dll!sofa::helper::logging::MessageDispatcher::LoggerStream::~LoggerStream() Line 198 C++
> Sofa.Core.dll!sofa::core::behavior::BaseForceField::buildStiffnessMatrix(sofa::core::behavior::StiffnessMatrix * matrix) Line 62 C++
Sofa.Component.LinearSolver.Direct.dll!sofa::component::linearsystem::AssemblingMatrixSystem<sofa::linearalgebra::BTDMatrix<6,double>,sofa::linearalgebra::BlockVector<6,double>>::contribute<0>(const sofa::core::MechanicalParams * mparams) Line 85 C++
Sofa.Component.LinearSolver.Direct.dll!sofa::component::linearsystem::AssemblingMatrixSystem<sofa::linearalgebra::BTDMatrix<6,double>,sofa::linearalgebra::BlockVector<6,double>>::assembleSystem(const sofa::core::MechanicalParams * mparams) Line 123 C++
Sofa.Core.dll!sofa::core::behavior::BaseMatrixLinearSystem::buildSystemMatrix(const sofa::core::MechanicalParams * mparams) Line 38 C++
Sofa.Component.LinearSolver.Direct.dll!sofa::component::linearsolver::MatrixLinearSolver<sofa::linearalgebra::BTDMatrix<6,double>,sofa::linearalgebra::BlockVector<6,double>,sofa::component::linearsolver::NoThreadManager>::setSystemMBKMatrix(const sofa::core::MechanicalParams * mparams) Line 241 C++
Sofa.Simulation.Core.dll!sofa::simulation::common::MechanicalOperations::m_setSystemMBKMatrix(double mFact, double bFact, double kFact) Line 455 C++
[Inline Frame] Sofa.Component.ODESolver.Backward.dll!sofa::core::behavior::MultiMatrix<sofa::simulation::common::MechanicalOperations>::setSystemMBKMatrix(const sofa::core::behavior::MechanicalMatrix & m) Line 71 C++
Sofa.Component.ODESolver.Backward.dll!sofa::component::odesolver::backward::EulerImplicitSolver::solve(const sofa::core::ExecParams * params, double dt, sofa::core::TMultiVecId<1,1> xResult, sofa::core::TMultiVecId<2,1> vResult) Line 154 C++
Sofa.Simulation.Core.dll!sofa::simulation::SolveVisitor::processSolver(sofa::simulation::Node * node, sofa::core::behavior::OdeSolver * s) Line 37 C++
Sofa.Simulation.Core.dll!sofa::simulation::Visitor::runVisitorTask<sofa::simulation::SolveVisitor,sofa::simulation::Node,sofa::core::behavior::OdeSolver>(sofa::simulation::SolveVisitor * visitor, sofa::simulation::Node * ctx, void(sofa::simulation::SolveVisitor::*)(sofa::simulation::Node *, sofa::core::behavior::OdeSolver *) task, sofa::core::behavior::OdeSolver * ptr, const std::string & typeInfo) Line 247 C++
It crashes when BaseForceField warns about buildStiffnessMatrix not implemented https://github.com/sofa-framework/sofa/blob/c4387feeb9e4a9f303b8cb63359ba31f1fd00493/Sofa/framework/Core/src/sofa/core/behavior/BaseForceField.cpp#L57
I think you already suspected that there was a problem with multithreading and the message mechanism somewhere...
I think this is this issue: https://github.com/sofa-framework/sofa/issues/3610
I think this is this issue: #3610
Yep it seems to be the same problem/symptom
Hi all,
It was tested two weeks ago at Defrost, @EulalieCoevoet try our tutorials/tripods and it works like a charm. @TanguyNav found a bug that was reported. To us, it is going in the right direction and we support the merge of this work.
We hope the rest of the community will provide feedback asap.
@alxbilger could you maybe share in the above PR description the link towards the doc page you prepared ?
[ci-build][full-build][with-all-tests]
1- small suggestions to remove warnings : https://github.com/alxbilger/sofa/pull/5 2- While solving the warnings, I saw (as usual) lots of warnings about signedness of indices for matrices... should we adjust this inconsistency once and for all (not in this PR but in the broader project of matrices) ?
[ci-build][with-all-tests]
[ci-depends-on] detected during build #93.
To unlock the merge button, you must
[ci-depends-on] detected during build #94.
To unlock the merge button, you must
[ci-depends-on] detected during build #95.
To unlock the merge button, you must
[ci-depends-on] detected during build #96.
To unlock the merge button, you must
[ci-depends-on] detected during build #97.
To unlock the merge button, you must
[ci-depends-on] detected during build #98.
To unlock the merge button, you must
[ci-depends-on] detected during build #99.
To unlock the merge button, you must
[ci-depends-on] detected during build #100.
To unlock the merge button, you must
[ci-depends-on] detected during build #101.
To unlock the merge button, you must
Ok for a merge on our side !
[ci-depends-on] detected during build #102.
To unlock the merge button, you must
[ci-depends-on] detected during build #103.
To unlock the merge button, you must
[ci-build][with-all-tests][force-full-build]
[ci-build][with-all-tests]
[ci-build][with-all-tests][force-full-build]
[ci-depends-on] detected during build #107.
To unlock the merge button, you must
[ci-build][with-all-tests][force-full-build]
[ci-depends-on] detected during build #108.
All dependencies are merged/closed and all ExternalProject pointers are up-to-date. Congrats! :+1:
[ci-build][with-all-tests]
[ci-depends-on] detected during build #110.
All dependencies are merged/closed and all ExternalProject pointers are up-to-date. Congrats! :+1:
[ci-build][with-all-tests][force-full-build]
[ci-depends-on] detected during build #111.
All dependencies are merged/closed and all ExternalProject pointers are up-to-date. Congrats! :+1:
[ci-build][with-all-tests][force-full-build]
[ci-depends-on] detected during build #112.
All dependencies are merged/closed and all ExternalProject pointers are up-to-date. Congrats! :+1:
An example of a plugin update further to this PR: https://github.com/SofaDefrost/SoftRobots/pull/213
Complete documentation here: https://notes.inria.fr/sP50g-5eT7-T3aEXXYcf4g (changes are possible)
Random things to have a look:
addKToMatrix
has been replaced bybuildStiffnessMatrix
addBToMatrix
has been replaced bybuildDampingMatrix
addMToMatrix
has been replaced bybuildMassMatrix
buildGeometricStiffnessMatrix
has been added to mappings and works similar tobuildStiffnessMatrix
andbuildDampingMatrix
.Sofa.Component.LinearSystem
LinearSystem
and its base classes (TypedMatrixLinearSystem
andBaseMatrixLinearSystem
)MatrixLinearSolver
, and how it interacts with a LinearSystemMappingGraph
MatrixLinearSystem
MatrixAccumulator.h
MatrixMapping.h
MatrixAPICompatibility.h
[ci-depends-on https://github.com/sofa-framework/Regression/pull/44] [ci-depends-on https://github.com/sofa-framework/SofaPython3/pull/343]
By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).
Reviewers will merge this pull-request only if