Skip to content

Commit 1961779

Browse files
authored
Apply name changing on code and examples (#342)
1 parent 2f44767 commit 1961779

62 files changed

Lines changed: 97 additions & 97 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

examples/component/constraint/CableConstraint/CableSmoothActuation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def createScene(rootNode):
3535
rootNode.addObject('VisualStyle', displayFlags='showVisualModels hideBehaviorModels showCollisionModels hideBoundingCollisionModels hideForceFields showInteractionForceFields hideWireframe')
3636

3737
rootNode.addObject('FreeMotionAnimationLoop')
38-
rootNode.addObject('ProjectedGaussSeidelConstraintSolver', printLog='0')
38+
rootNode.addObject('BlockGaussSeidelConstraintSolver', printLog='0')
3939

4040
################################################################################################################
4141
################################################### Bunny ######################################################

examples/component/constraint/CableConstraint/DisplacementVsForceControl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def createScene(rootNode):
1717
"Sofa.Component.Collision.Response.Contact", # Needed to use components RuleBasedContactManager
1818
"Sofa.Component.Constraint.Lagrangian.Correction",
1919
# Needed to use components LinearSolverConstraintCorrection
20-
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components ProjectedGaussSeidelConstraintSolver
20+
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components BlockGaussSeidelConstraintSolver
2121
"Sofa.Component.Engine.Select", # Needed to use components BoxROI
2222
"Sofa.Component.IO.Mesh", # Needed to use components MeshSTLLoader, MeshVTKLoader
2323
"Sofa.Component.LinearSolver.Direct", # Needed to use components SparseLDLSolver

examples/component/constraint/CableConstraint/Finger.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ def createScene(rootNode):
1111
rootNode.addObject('RequiredPlugin', pluginName=[
1212
"Sofa.Component.AnimationLoop", # Needed to use components FreeMotionAnimationLoop
1313
"Sofa.Component.Constraint.Lagrangian.Correction", # Needed to use components GenericConstraintCorrection
14-
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components ProjectedGaussSeidelConstraintSolver
14+
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components BlockGaussSeidelConstraintSolver
1515
"Sofa.Component.Engine.Select", # Needed to use components BoxROI
1616
"Sofa.Component.IO.Mesh", # Needed to use components MeshSTLLoader, MeshVTKLoader
1717
"Sofa.Component.LinearSolver.Direct", # Needed to use components SparseLDLSolver
@@ -34,8 +34,8 @@ def createScene(rootNode):
3434
# when manipulating the robots by specifying their effector's position instead of by direct control
3535
#  of the actuator's parameters.
3636
# rootNode.addObject('QPInverseProblemSolver', printLog=False)
37-
# Otherwise use a ProjectedGaussSeidelConstraintSolver
38-
rootNode.addObject('ProjectedGaussSeidelConstraintSolver', tolerance=1e-5, maxIterations=100)
37+
# Otherwise use a BlockGaussSeidelConstraintSolver
38+
rootNode.addObject('BlockGaussSeidelConstraintSolver', tolerance=1e-5, maxIterations=100)
3939

4040
rootNode.gravity = [0, -9810, 0]
4141
rootNode.dt = 0.01

examples/component/constraint/CableConstraint/FingerWithSTLIB.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ def createScene(rootNode):
1919
"Sofa.Component.AnimationLoop", # Needed to use components FreeMotionAnimationLoop
2020
"Sofa.Component.Constraint.Lagrangian.Correction",
2121
# Needed to use components LinearSolverConstraintCorrection
22-
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components ProjectedGaussSeidelConstraintSolver
22+
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components BlockGaussSeidelConstraintSolver
2323
"Sofa.Component.Engine.Select", # Needed to use components BoxROI
2424
"Sofa.Component.IO.Mesh", # Needed to use components MeshSTLLoader, MeshVTKLoader
2525
"Sofa.Component.LinearSolver.Direct", # Needed to use components SparseLDLSolver
@@ -36,7 +36,7 @@ def createScene(rootNode):
3636

3737
rootNode.addObject("FreeMotionAnimationLoop")
3838
rootNode.addObject('DefaultVisualManagerLoop')
39-
rootNode.addObject("ProjectedGaussSeidelConstraintSolver", maxIterations=1000, tolerance=0.001)
39+
rootNode.addObject("BlockGaussSeidelConstraintSolver", maxIterations=1000, tolerance=0.001)
4040

4141
finger = ElasticMaterialObject(name="finger",
4242
volumeMeshFileName="mesh/finger.vtk",

examples/component/constraint/JointConstraint/JointConstraint.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def createScene(rootNode):
1010
rootNode.addObject('RequiredPlugin', name='ArticulatedSystemPlugin') # Needed to use components [ArticulatedHierarchyContainer,ArticulatedSystemMapping,Articulation,ArticulationCenter]
1111
rootNode.addObject('RequiredPlugin', name='Sofa.Component.AnimationLoop') # Needed to use components [FreeMotionAnimationLoop]
1212
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Constraint.Lagrangian.Correction') # Needed to use components [UncoupledConstraintCorrection]
13-
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Constraint.Lagrangian.Solver') # Needed to use components [ProjectedGaussSeidelConstraintSolver]
13+
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Constraint.Lagrangian.Solver') # Needed to use components [BlockGaussSeidelConstraintSolver]
1414
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Constraint.Projective') # Needed to use components [FixedProjectiveConstraint]
1515
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Engine.Generate') # Needed to use components [GenerateRigidMass]
1616
rootNode.addObject('RequiredPlugin', name='Sofa.Component.IO.Mesh') # Needed to use components [MeshSTLLoader]
@@ -28,7 +28,7 @@ def createScene(rootNode):
2828
rootNode.gravity = [0., -9810., 0.]
2929
rootNode.addObject('VisualStyle', displayFlags='showBehaviorModels')
3030
rootNode.addObject('FreeMotionAnimationLoop')
31-
rootNode.addObject('ProjectedGaussSeidelConstraintSolver', maxIterations=500, tolerance=1e-4)
31+
rootNode.addObject('BlockGaussSeidelConstraintSolver', maxIterations=500, tolerance=1e-4)
3232

3333
# Simulation node
3434
simulation = rootNode.addChild('Simulation')

examples/component/constraint/PositionConstraint/PositionConstraint.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ def createScene(rootnode):
33
rootnode.addObject('RequiredPlugin', name='SoftRobots')
44

55
rootnode.addObject('FreeMotionAnimationLoop')
6-
rootnode.addObject('ProjectedGaussSeidelConstraintSolver', maxIterations=1e4, tolerance=1e-5, printLog=True)
6+
rootnode.addObject('BlockGaussSeidelConstraintSolver', maxIterations=1e4, tolerance=1e-5, printLog=True)
77
rootnode.gravity = [0, -9.81, 0]
88
rootnode.addObject('VisualStyle', displayFlags='showForceFields')
99

examples/component/constraint/SurfacePressureConstraint/PressureVsVolumeGrowthControl.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def createScene(rootNode):
1313
"Sofa.Component.AnimationLoop", # Needed to use components FreeMotionAnimationLoop
1414
"Sofa.Component.Constraint.Lagrangian.Correction",
1515
# Needed to use components LinearSolverConstraintCorrection
16-
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components ProjectedGaussSeidelConstraintSolver
16+
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components BlockGaussSeidelConstraintSolver
1717
"Sofa.Component.Engine.Select", # Needed to use components BoxROI
1818
"Sofa.Component.IO.Mesh", # Needed to use components MeshOBJLoader, MeshVTKLoader
1919
"Sofa.Component.LinearSolver.Direct", # Needed to use components SparseLDLSolver
@@ -36,7 +36,7 @@ def createScene(rootNode):
3636

3737
rootNode.addObject('FreeMotionAnimationLoop')
3838
rootNode.addObject('DefaultVisualManagerLoop')
39-
rootNode.addObject('ProjectedGaussSeidelConstraintSolver', maxIterations=500, printLog=False, tolerance=0.0000001)
39+
rootNode.addObject('BlockGaussSeidelConstraintSolver', maxIterations=500, printLog=False, tolerance=0.0000001)
4040

4141
Bunny(rootNode, name='BunnyPressure', controlType='pressure', initialValue=2)
4242
Bunny(rootNode, translation=[15, 0, 0], controlType='volumeGrowth', name='BunnyVolume', initialValue=40)

examples/component/constraint/SurfacePressureConstraint/Springy.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def createScene(rootNode):
1414
"Sofa.Component.AnimationLoop", # Needed to use components FreeMotionAnimationLoop
1515
"Sofa.Component.Constraint.Lagrangian.Correction",
1616
# Needed to use components LinearSolverConstraintCorrection
17-
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components ProjectedGaussSeidelConstraintSolver
17+
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components BlockGaussSeidelConstraintSolver
1818
"Sofa.Component.Engine.Select", # Needed to use components BoxROI
1919
"Sofa.Component.IO.Mesh", # Needed to use components MeshSTLLoader, MeshVTKLoader
2020
"Sofa.Component.LinearSolver.Direct", # Needed to use components SparseLDLSolver
@@ -33,7 +33,7 @@ def createScene(rootNode):
3333
rootNode.addObject('FreeMotionAnimationLoop')
3434
rootNode.addObject('DefaultVisualManagerLoop')
3535

36-
rootNode.addObject('ProjectedGaussSeidelConstraintSolver', maxIterations=1000, tolerance=1e-3)
36+
rootNode.addObject('BlockGaussSeidelConstraintSolver', maxIterations=1000, tolerance=1e-3)
3737

3838
rootNode.addObject('BackgroundSetting', color=[0, 0.168627, 0.211765, 1])
3939
rootNode.findData('gravity').value = [0, 0, -981.0]

examples/component/constraint/SurfacePressureConstraint/SurfacePressureConstraint.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ def createScene(rootNode):
88

99
rootNode.addObject('RequiredPlugin', name='Sofa.Component.AnimationLoop') # Needed to use components [FreeMotionAnimationLoop]
1010
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Constraint.Lagrangian.Correction') # Needed to use components [LinearSolverConstraintCorrection]
11-
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Constraint.Lagrangian.Solver') # Needed to use components [ProjectedGaussSeidelConstraintSolver]
11+
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Constraint.Lagrangian.Solver') # Needed to use components [BlockGaussSeidelConstraintSolver]
1212
rootNode.addObject('RequiredPlugin', name='Sofa.Component.Engine.Select') # Needed to use components [BoxROI]
1313
rootNode.addObject('RequiredPlugin', name='Sofa.Component.IO.Mesh') # Needed to use components [MeshOBJLoader,MeshVTKLoader]
1414
rootNode.addObject('RequiredPlugin', name='Sofa.Component.LinearSolver.Direct') # Needed to use components [EigenSimplicialLDLT]
@@ -32,7 +32,7 @@ def createScene(rootNode):
3232

3333
rootNode.addObject('FreeMotionAnimationLoop')
3434
rootNode.addObject('DefaultVisualManagerLoop')
35-
rootNode.addObject('ProjectedGaussSeidelConstraintSolver', maxIterations=100, tolerance=0.0000001)
35+
rootNode.addObject('BlockGaussSeidelConstraintSolver', maxIterations=100, tolerance=0.0000001)
3636

3737
# bunny
3838
bunny = rootNode.addChild('bunny')

examples/component/constraint/UnilateralPlaneConstraint/ArticulatedTentacle.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def createScene(rootNode):
1818
"Sofa.Component.Collision.Response.Contact", # Needed to use components CollisionResponse
1919
"Sofa.Component.Constraint.Lagrangian.Correction",
2020
# Needed to use components LinearSolverConstraintCorrection
21-
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components ProjectedGaussSeidelConstraintSolver
21+
"Sofa.Component.Constraint.Lagrangian.Solver", # Needed to use components BlockGaussSeidelConstraintSolver
2222
"Sofa.Component.Engine.Select", # Needed to use components BoxROI
2323
"Sofa.Component.IO.Mesh", # Needed to use components MeshSTLLoader, MeshVTKLoader
2424
"Sofa.Component.LinearSolver.Direct", # Needed to use components SparseLDLSolver
@@ -35,7 +35,7 @@ def createScene(rootNode):
3535
rootNode.addObject('VisualStyle', displayFlags="showVisualModels hideBehaviorModels showCollisionModels hideBoundingCollisionModels hideForceFields showInteractionForceFields hideWireframe")
3636
rootNode.addObject('FreeMotionAnimationLoop')
3737
rootNode.addObject('DefaultVisualManagerLoop')
38-
rootNode.addObject('ProjectedGaussSeidelConstraintSolver', maxIterations=1000, tolerance=1e-3)
38+
rootNode.addObject('BlockGaussSeidelConstraintSolver', maxIterations=1000, tolerance=1e-3)
3939

4040
rootNode.addObject('CollisionPipeline')
4141
rootNode.addObject('BruteForceBroadPhase', name="N2")

0 commit comments

Comments
 (0)