Skip to content

[SofaPython3] Changes how addObject process its arguments when they are of type: numpy & data - #198

Merged
damienmarchal merged 10 commits into
sofa-framework:masterfrom
CRIStAL-PADR:pr-add-createobject-behavior
Nov 3, 2021
Merged

[SofaPython3] Changes how addObject process its arguments when they are of type: numpy & data #198
damienmarchal merged 10 commits into
sofa-framework:masterfrom
CRIStAL-PADR:pr-add-createobject-behavior

Conversation

@damienmarchal

@damienmarchaldamienmarchal commented Sep 23, 2021

Copy link
Copy Markdown
Contributor

The PR changes how addObject is handling some parameter according to their type.

numpy array

When passing a numpy array to the addObject simply does not work reporting an unparsable string.
Eg:

node.addObject("MeshObjLoader", name=loader)
node.addObject("MechanicalObject", position=node.loader.position.value)

This does not work because position.value is of type numpy and that the object creation is trying to do a string conversion (which does not returns string parsable by Sofa). The PR detect numpy arrays and implement the proper conversion.

Data fields

When passing a BaseData object to the addObject the current implementation is copying the data.
Eg:

node.addObject("MeshObjLoader", name=loader)
node.addObject("MechanicalObject", position=node.loader.position)

It was discussed in #197 what should be the most appropriate scenario.
This PR implement the following scenario:

defcreateScene(root):
root.addObject("MeshObjLoader", filename="mesh/cube.obj", name="loader");
a=root.addObject("PointSetTopologyContainer", position=root.loader.position.linkpath, name="topo") # explicitly makes a linkb=root.addObject("PointSetTopologyContainer", position=root.loader.position.value, name="topo") # explicitly makes copyc=root.addObject("PointSetTopologyContainer", position=root.loader.position, name="topo") # implicitly makes a link 

It is yet undecided if we prevent the implicit version, and if we keep it if it should makes a link or a copy.

NB: the tests for linkpath will fails until the following sofa PR: sofa-framework/sofa#2354
is not merged.

…ing (in object creation)
So we can write:
```python
def createScene(root):
root.addObject("MechanicalObject", name="loader", filename="mesh/cube.obj")
root.addObject("MechanicalObject", name="dofs", position=root.loader.position) # to make a link
root.addObject("MechanicalObject", name="dofs", position=root.loader.position.value) # to make a copy by value
```
…ring
Because it breaks bckward compatibility and was not really better.
So we can write:
object.position.link instead of object.position.getLinkPath()
Which will make the syntax a bit more compact.
Signed-off-by: Damien Marchal <damien.marchal@univ-lille1.fr>
Signed-off-by: Damien Marchal <damien.marchal@univ-lille1.fr>
@damienmarchal

Copy link
Copy Markdown
ContributorAuthor

tests are passing now (not the one with 21.06...but this is expected)

@hugtalbot

Copy link
Copy Markdown
Contributor

it works for me ! 👍
I will add this in the SP3 doc !

@hugtalbothugtalbot added pr: breaking pr: new feature pr: highlighted in next release Highlight this contribution in the notes of the upcoming release labels Oct 11, 2021
hugtalbot added a commit to hugtalbot/SofaPython3 that referenced this pull request Oct 11, 2021
@damienmarchal

Copy link
Copy Markdown
ContributorAuthor

I remember a long time ago there was a rule saying that a PR without a "no go message" for more than seven days were considered as ready to merge.

This one is on-hold for 19 days now.

@guparanguparan modified the milestones: v21.06, v21.12Oct 26, 2021
@damienmarchal

Copy link
Copy Markdown
ContributorAuthor

@hugtalbot, @fredroy the changes requested are done.

@damienmarchal
damienmarchal merged commit 166f7f5 into sofa-framework:masterNov 3, 2021
@damienmarchal
damienmarchal deleted the pr-add-createobject-behavior branch November 3, 2021 10:11
fredroy pushed a commit that referenced this pull request Feb 26, 2026
* [examples] Add a thermo-elastic example
* minor comment to remove
* Get compatible with #198 and add legend
* Remove option of topo changes
* Update scene further to recently introduced templates in Mass
* avoid using strings
* update scene with imgui, linkpath etc
---------
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
bakpaul added a commit that referenced this pull request Mar 2, 2026
commit 833bd69
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Fri Feb 27 00:40:59 2026 +0100
[doc] Use sphinx-design in order to fix doc generation (#586)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit d982bc8
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Feb 26 23:11:32 2026 +0100
Remove unappropriate comment (#591)
commit ae7e8e1
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 18:39:56 2026 +0100
Ignore the meshing scenes (#587)
commit 6593f34
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 18:38:58 2026 +0100
[RPyC] Add new exposed methods to SOFA server (#570)
* Add a way to init the root remotly
* Add method to change working dir on remote
commit bdbaece
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 10:29:37 2026 +0100
Add python modules that uses the CGAL binding (#567)
* Add python modules that uses the CGAL binding instead of the CGALPlugin to generate mesh from a pointcloud or a surfacic polyhedron
* Add a SOFA scene opening and using the generated mesh with CGAL
* Sort all files into a meshing repo and add a Gmsh example
* Make display optionnal
* Fix typo
---------
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
Co-authored-by: Themis Skamagkis <70031729+th-skam@users.noreply.github.com>
commit 617d506
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Thu Feb 26 10:29:13 2026 +0100
[examples] Add a thermo-elastic example (#204)
* [examples] Add a thermo-elastic example
* minor comment to remove
* Get compatible with #198 and add legend
* Remove option of topo changes
* Update scene further to recently introduced templates in Mass
* avoid using strings
* update scene with imgui, linkpath etc
---------
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit 4fb7e89
Author: leobois67 <leo.bois@inria.fr>
Date: Wed Feb 25 18:58:24 2026 +0100
Example of a ForceField implemented with JAX (#557)
* Add the example
* Igne jax example on main CI
* Fix ignoring the jax examples
* Fix addKToMatrix() with different options
* Apply suggestions from code review
---------
Co-authored-by: Paul Baksic <paul.baksic@outlook.fr>
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit b3a79c6
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Wed Feb 25 15:50:54 2026 +0100
Fix code block indentation for createScene function (#582)
Updated code block formatting for createScene function.
This should fix the doc generation
commit fc75967
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:51 2026 +0100
fix wrong parameter order in addDForce and addKToMatrix (#579)
* fix wrong parameter order in addDForce
* also fix addKToMatrix
commit ca2be7c
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:37 2026 +0100
Add bindings for prism and pyramid topology functions (#578)
commit 346d298
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:20 2026 +0100
ordering field is deprecated, use NaturalOrderingMethod instead (#577)
commit 959b4cd
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:02 2026 +0100
Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler (#576)
* Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler.
* cleaning
* Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler.
commit c0dc30e
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Feb 12 10:43:05 2026 +0100
Clean getRecords in Timer module (#561)
* Clean getRecords in Timer module
* remove extra /**
commit d2ba475
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Wed Feb 4 23:59:52 2026 +0100
include `sofa/core/fwd.h` instead of the forward declaration (#575)
commit c209f3a
Author: Frederick Roy <fredroy@users.noreply.github.com>
Date: Wed Feb 4 22:50:20 2026 +0900
fix mixed-up quote/doublequote, plus consistent quoting (#574)
commit 7760402
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Tue Feb 3 08:05:33 2026 +0100
Generalize use of initRoot (#566)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit b29cfe5
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Jan 29 20:19:43 2026 +0100
Remove the implementation of getPathName as it is now in BaseData (#556)
See: sofa-framework/sofa#5759
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit c7fb254
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Jan 29 20:08:22 2026 +0100
Introduce an example of a custom message handler (#569)
commit f4e90d4
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Thu Jan 29 09:00:43 2026 +0100
Follow lifecycle v26.06 deprecated header (#571)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit 8bf0162
Author: Frederick Roy <fredroy@users.noreply.github.com>
Date: Wed Jan 7 06:48:05 2026 +0900
remove import of scipy.misc, which is deprecated (#564)
commit 1016b94
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Dec 18 16:37:52 2025 +0100
Update advanced_timer.py with comments and fix deprecated data (#562)
commit 29c4e87
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Tue Dec 16 12:01:32 2025 +0100
Add example scene using CCDTightInclusion (#559)
* Add example scene using CCDTightInclusion
* Replace ProjectedGaussSeidel with BlockGaussSeidel
* Fix scene error
commit d38d3c4
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Fri Dec 12 11:53:20 2025 +0100
Apply name changing on code and examples (#560)
commit b09d921
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:28:05 2025 +0100
Add Quaternion to python factory so we can create data field with this type. (#555)
commit a66c054
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:27:48 2025 +0100
Improve error message when the SetDataFromArray does not match (#554)
* Improve error message when the SetDataFromArray does not match
* Apply suggestions from code review
---------
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit 746745c
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:27:28 2025 +0100
Add context manager behavior to Node() (#545)
This allows to use with statment to have good looking indentation in sofa scene.
eg:
with Node("YOLO") as w:
w.addObject("YY")
commit af98611
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 13 15:25:55 2025 +0100
Support more types of linear systems (#542)
* Support more types of linear systems
* add support for BTD
commit ae6b330
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 13 10:35:28 2025 +0100
add missing required plugin in test (#558)
commit 6ef05ed
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Tue Nov 11 14:34:26 2025 +0100
Fix binding after #5648 (#528)
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit 5029c05
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 6 10:24:24 2025 +0100
Add validation for numpy array as return type in AddKToMatrix bindings (#541)
* Add validation for numpy array as return type in AddKToMatrix bindings
* Refactor AddKToMatrix return type validation and simplify conditional checks
commit 8ba1e2c
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Oct 30 16:06:25 2025 +0100
Register in the PythonFactory Rigid3::Coord (#544)
Because currently only Rigid3::VecCoord was supported.
commit 72ed0e6
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Oct 30 16:06:16 2025 +0100
Add proper return value to event overriden in python (#543)
Currently the controllers implemented in python cannot report the the event processing
system in sofa that there is no need anymore to process the event.
The PR allows to do. Every onXXXXXX() that implement an event processor can no return a value.
If it is None or False then processing of event use this to continue the propagation
If it is True (aka: has been processed/no more further), then the SOFA system will not proposed to other component to process the same event
bakpaul added a commit to bakpaul/SofaPython3 that referenced this pull request Mar 2, 2026
commit 539badc
Author: bakpaul <paul.baksic@outlook.fr>
Date: Mon Mar 2 09:10:20 2026 +0100
Squashed commit of the following:
commit 833bd69
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Fri Feb 27 00:40:59 2026 +0100
[doc] Use sphinx-design in order to fix doc generation (sofa-framework#586)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit d982bc8
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Feb 26 23:11:32 2026 +0100
Remove unappropriate comment (sofa-framework#591)
commit ae7e8e1
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 18:39:56 2026 +0100
Ignore the meshing scenes (sofa-framework#587)
commit 6593f34
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 18:38:58 2026 +0100
[RPyC] Add new exposed methods to SOFA server (sofa-framework#570)
* Add a way to init the root remotly
* Add method to change working dir on remote
commit bdbaece
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 10:29:37 2026 +0100
Add python modules that uses the CGAL binding (sofa-framework#567)
* Add python modules that uses the CGAL binding instead of the CGALPlugin to generate mesh from a pointcloud or a surfacic polyhedron
* Add a SOFA scene opening and using the generated mesh with CGAL
* Sort all files into a meshing repo and add a Gmsh example
* Make display optionnal
* Fix typo
---------
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
Co-authored-by: Themis Skamagkis <70031729+th-skam@users.noreply.github.com>
commit 617d506
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Thu Feb 26 10:29:13 2026 +0100
[examples] Add a thermo-elastic example (sofa-framework#204)
* [examples] Add a thermo-elastic example
* minor comment to remove
* Get compatible with sofa-framework#198 and add legend
* Remove option of topo changes
* Update scene further to recently introduced templates in Mass
* avoid using strings
* update scene with imgui, linkpath etc
---------
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit 4fb7e89
Author: leobois67 <leo.bois@inria.fr>
Date: Wed Feb 25 18:58:24 2026 +0100
Example of a ForceField implemented with JAX (sofa-framework#557)
* Add the example
* Igne jax example on main CI
* Fix ignoring the jax examples
* Fix addKToMatrix() with different options
* Apply suggestions from code review
---------
Co-authored-by: Paul Baksic <paul.baksic@outlook.fr>
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit b3a79c6
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Wed Feb 25 15:50:54 2026 +0100
Fix code block indentation for createScene function (sofa-framework#582)
Updated code block formatting for createScene function.
This should fix the doc generation
commit fc75967
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:51 2026 +0100
fix wrong parameter order in addDForce and addKToMatrix (sofa-framework#579)
* fix wrong parameter order in addDForce
* also fix addKToMatrix
commit ca2be7c
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:37 2026 +0100
Add bindings for prism and pyramid topology functions (sofa-framework#578)
commit 346d298
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:20 2026 +0100
ordering field is deprecated, use NaturalOrderingMethod instead (sofa-framework#577)
commit 959b4cd
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:02 2026 +0100
Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler (sofa-framework#576)
* Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler.
* cleaning
* Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler.
commit c0dc30e
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Feb 12 10:43:05 2026 +0100
Clean getRecords in Timer module (sofa-framework#561)
* Clean getRecords in Timer module
* remove extra /**
commit d2ba475
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Wed Feb 4 23:59:52 2026 +0100
include `sofa/core/fwd.h` instead of the forward declaration (sofa-framework#575)
commit c209f3a
Author: Frederick Roy <fredroy@users.noreply.github.com>
Date: Wed Feb 4 22:50:20 2026 +0900
fix mixed-up quote/doublequote, plus consistent quoting (sofa-framework#574)
commit 7760402
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Tue Feb 3 08:05:33 2026 +0100
Generalize use of initRoot (sofa-framework#566)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit b29cfe5
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Jan 29 20:19:43 2026 +0100
Remove the implementation of getPathName as it is now in BaseData (sofa-framework#556)
See: sofa-framework/sofa#5759
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit c7fb254
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Jan 29 20:08:22 2026 +0100
Introduce an example of a custom message handler (sofa-framework#569)
commit f4e90d4
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Thu Jan 29 09:00:43 2026 +0100
Follow lifecycle v26.06 deprecated header (sofa-framework#571)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit 8bf0162
Author: Frederick Roy <fredroy@users.noreply.github.com>
Date: Wed Jan 7 06:48:05 2026 +0900
remove import of scipy.misc, which is deprecated (sofa-framework#564)
commit 1016b94
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Dec 18 16:37:52 2025 +0100
Update advanced_timer.py with comments and fix deprecated data (sofa-framework#562)
commit 29c4e87
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Tue Dec 16 12:01:32 2025 +0100
Add example scene using CCDTightInclusion (sofa-framework#559)
* Add example scene using CCDTightInclusion
* Replace ProjectedGaussSeidel with BlockGaussSeidel
* Fix scene error
commit d38d3c4
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Fri Dec 12 11:53:20 2025 +0100
Apply name changing on code and examples (sofa-framework#560)
commit b09d921
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:28:05 2025 +0100
Add Quaternion to python factory so we can create data field with this type. (sofa-framework#555)
commit a66c054
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:27:48 2025 +0100
Improve error message when the SetDataFromArray does not match (sofa-framework#554)
* Improve error message when the SetDataFromArray does not match
* Apply suggestions from code review
---------
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit 746745c
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:27:28 2025 +0100
Add context manager behavior to Node() (sofa-framework#545)
This allows to use with statment to have good looking indentation in sofa scene.
eg:
with Node("YOLO") as w:
w.addObject("YY")
commit af98611
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 13 15:25:55 2025 +0100
Support more types of linear systems (sofa-framework#542)
* Support more types of linear systems
* add support for BTD
commit ae6b330
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 13 10:35:28 2025 +0100
add missing required plugin in test (sofa-framework#558)
commit 6ef05ed
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Tue Nov 11 14:34:26 2025 +0100
Fix binding after #5648 (sofa-framework#528)
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit 5029c05
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 6 10:24:24 2025 +0100
Add validation for numpy array as return type in AddKToMatrix bindings (sofa-framework#541)
* Add validation for numpy array as return type in AddKToMatrix bindings
* Refactor AddKToMatrix return type validation and simplify conditional checks
commit 8ba1e2c
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Oct 30 16:06:25 2025 +0100
Register in the PythonFactory Rigid3::Coord (sofa-framework#544)
Because currently only Rigid3::VecCoord was supported.
commit 72ed0e6
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Oct 30 16:06:16 2025 +0100
Add proper return value to event overriden in python (sofa-framework#543)
Currently the controllers implemented in python cannot report the the event processing
system in sofa that there is no need anymore to process the event.
The PR allows to do. Every onXXXXXX() that implement an event processor can no return a value.
If it is None or False then processing of event use this to continue the propagation
If it is True (aka: has been processed/no more further), then the SOFA system will not proposed to other component to process the same event
bakpaul added a commit to bakpaul/SofaPython3 that referenced this pull request Apr 9, 2026
commit 833bd69
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Fri Feb 27 00:40:59 2026 +0100
[doc] Use sphinx-design in order to fix doc generation (sofa-framework#586)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit d982bc8
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Feb 26 23:11:32 2026 +0100
Remove unappropriate comment (sofa-framework#591)
commit ae7e8e1
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 18:39:56 2026 +0100
Ignore the meshing scenes (sofa-framework#587)
commit 6593f34
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 18:38:58 2026 +0100
[RPyC] Add new exposed methods to SOFA server (sofa-framework#570)
* Add a way to init the root remotly
* Add method to change working dir on remote
commit bdbaece
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Thu Feb 26 10:29:37 2026 +0100
Add python modules that uses the CGAL binding (sofa-framework#567)
* Add python modules that uses the CGAL binding instead of the CGALPlugin to generate mesh from a pointcloud or a surfacic polyhedron
* Add a SOFA scene opening and using the generated mesh with CGAL
* Sort all files into a meshing repo and add a Gmsh example
* Make display optionnal
* Fix typo
---------
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
Co-authored-by: Themis Skamagkis <70031729+th-skam@users.noreply.github.com>
commit 617d506
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Thu Feb 26 10:29:13 2026 +0100
[examples] Add a thermo-elastic example (sofa-framework#204)
* [examples] Add a thermo-elastic example
* minor comment to remove
* Get compatible with sofa-framework#198 and add legend
* Remove option of topo changes
* Update scene further to recently introduced templates in Mass
* avoid using strings
* update scene with imgui, linkpath etc
---------
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit 4fb7e89
Author: leobois67 <leo.bois@inria.fr>
Date: Wed Feb 25 18:58:24 2026 +0100
Example of a ForceField implemented with JAX (sofa-framework#557)
* Add the example
* Igne jax example on main CI
* Fix ignoring the jax examples
* Fix addKToMatrix() with different options
* Apply suggestions from code review
---------
Co-authored-by: Paul Baksic <paul.baksic@outlook.fr>
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit b3a79c6
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Wed Feb 25 15:50:54 2026 +0100
Fix code block indentation for createScene function (sofa-framework#582)
Updated code block formatting for createScene function.
This should fix the doc generation
commit fc75967
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:51 2026 +0100
fix wrong parameter order in addDForce and addKToMatrix (sofa-framework#579)
* fix wrong parameter order in addDForce
* also fix addKToMatrix
commit ca2be7c
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:37 2026 +0100
Add bindings for prism and pyramid topology functions (sofa-framework#578)
commit 346d298
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:20 2026 +0100
ordering field is deprecated, use NaturalOrderingMethod instead (sofa-framework#577)
commit 959b4cd
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Fri Feb 13 03:42:02 2026 +0100
Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler (sofa-framework#576)
* Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler.
* cleaning
* Redirect SOFA logs to Python's sys.stdout using a custom PythonMessageHandler.
commit c0dc30e
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Feb 12 10:43:05 2026 +0100
Clean getRecords in Timer module (sofa-framework#561)
* Clean getRecords in Timer module
* remove extra /**
commit d2ba475
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Wed Feb 4 23:59:52 2026 +0100
include `sofa/core/fwd.h` instead of the forward declaration (sofa-framework#575)
commit c209f3a
Author: Frederick Roy <fredroy@users.noreply.github.com>
Date: Wed Feb 4 22:50:20 2026 +0900
fix mixed-up quote/doublequote, plus consistent quoting (sofa-framework#574)
commit 7760402
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Tue Feb 3 08:05:33 2026 +0100
Generalize use of initRoot (sofa-framework#566)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit b29cfe5
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Jan 29 20:19:43 2026 +0100
Remove the implementation of getPathName as it is now in BaseData (sofa-framework#556)
See: sofa-framework/sofa#5759
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit c7fb254
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Jan 29 20:08:22 2026 +0100
Introduce an example of a custom message handler (sofa-framework#569)
commit f4e90d4
Author: Hugo <hugo.talbot@sofa-framework.org>
Date: Thu Jan 29 09:00:43 2026 +0100
Follow lifecycle v26.06 deprecated header (sofa-framework#571)
Co-authored-by: hugtalbot <hugo.talbot@inria.fr>
commit 8bf0162
Author: Frederick Roy <fredroy@users.noreply.github.com>
Date: Wed Jan 7 06:48:05 2026 +0900
remove import of scipy.misc, which is deprecated (sofa-framework#564)
commit 1016b94
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Dec 18 16:37:52 2025 +0100
Update advanced_timer.py with comments and fix deprecated data (sofa-framework#562)
commit 29c4e87
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Tue Dec 16 12:01:32 2025 +0100
Add example scene using CCDTightInclusion (sofa-framework#559)
* Add example scene using CCDTightInclusion
* Replace ProjectedGaussSeidel with BlockGaussSeidel
* Fix scene error
commit d38d3c4
Author: Paul Baksic <30337881+bakpaul@users.noreply.github.com>
Date: Fri Dec 12 11:53:20 2025 +0100
Apply name changing on code and examples (sofa-framework#560)
commit b09d921
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:28:05 2025 +0100
Add Quaternion to python factory so we can create data field with this type. (sofa-framework#555)
commit a66c054
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:27:48 2025 +0100
Improve error message when the SetDataFromArray does not match (sofa-framework#554)
* Improve error message when the SetDataFromArray does not match
* Apply suggestions from code review
---------
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit 746745c
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Nov 13 15:27:28 2025 +0100
Add context manager behavior to Node() (sofa-framework#545)
This allows to use with statment to have good looking indentation in sofa scene.
eg:
with Node("YOLO") as w:
w.addObject("YY")
commit af98611
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 13 15:25:55 2025 +0100
Support more types of linear systems (sofa-framework#542)
* Support more types of linear systems
* add support for BTD
commit ae6b330
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 13 10:35:28 2025 +0100
add missing required plugin in test (sofa-framework#558)
commit 6ef05ed
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Tue Nov 11 14:34:26 2025 +0100
Fix binding after #5648 (sofa-framework#528)
Co-authored-by: Hugo <hugo.talbot@sofa-framework.org>
commit 5029c05
Author: Alex Bilger <alxbilger@users.noreply.github.com>
Date: Thu Nov 6 10:24:24 2025 +0100
Add validation for numpy array as return type in AddKToMatrix bindings (sofa-framework#541)
* Add validation for numpy array as return type in AddKToMatrix bindings
* Refactor AddKToMatrix return type validation and simplify conditional checks
commit 8ba1e2c
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Oct 30 16:06:25 2025 +0100
Register in the PythonFactory Rigid3::Coord (sofa-framework#544)
Because currently only Rigid3::VecCoord was supported.
commit 72ed0e6
Author: Damien Marchal <damien.marchal@univ-lille1.fr>
Date: Thu Oct 30 16:06:16 2025 +0100
Add proper return value to event overriden in python (sofa-framework#543)
Currently the controllers implemented in python cannot report the the event processing
system in sofa that there is no need anymore to process the event.
The PR allows to do. Every onXXXXXX() that implement an event processor can no return a value.
If it is None or False then processing of event use this to continue the propagation
If it is True (aka: has been processed/no more further), then the SOFA system will not proposed to other component to process the same event
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr: breakingpr: highlighted in next releaseHighlight this contribution in the notes of the upcoming releasepr: new featurepr: status ready

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@damienmarchal@hugtalbot@guparan