Fix Problem::RemoveParameterBlock documentation Ordering of Problem::RemoveParameterBlock and Problem::RemoveResidualBlock changed, as RemoveResidualBlock is being referred in RemoveParameterBlock with "above". Change-Id: I07f8e7b7e20ba239a72c15ed9e79576f5def090a
diff --git a/docs/source/modeling.rst b/docs/source/modeling.rst index 95832b1..8e6de12 100644 --- a/docs/source/modeling.rst +++ b/docs/source/modeling.rst
@@ -1271,6 +1271,19 @@ .. function:: void Problem::RemoveResidualBlock(ResidualBlockId residual_block) + Remove a residual block from the problem. Any parameters that the residual + block depends on are not removed. The cost and loss functions for the + residual block will not get deleted immediately; won't happen until the + problem itself is deleted. + + **WARNING:** Removing a residual or parameter block will destroy + the implicit ordering, rendering the jacobian or residuals returned + from the solver uninterpretable. If you depend on the evaluated + jacobian, do not use remove! This may change in a future release. + Hold the indicated parameter block constant during optimization. + +.. function:: void Problem::RemoveParameterBlock(double* values) + Remove a parameter block from the problem. The parameterization of the parameter block, if it exists, will persist until the deletion of the problem (similar to cost/loss functions in residual block @@ -1285,20 +1298,6 @@ from the solver uninterpretable. If you depend on the evaluated jacobian, do not use remove! This may change in a future release. -.. function:: void Problem::RemoveResidualBlock(ResidualBlockId residual_block) - - Remove a residual block from the problem. Any parameters that the residual - block depends on are not removed. The cost and loss functions for the - residual block will not get deleted immediately; won't happen until the - problem itself is deleted. - - **WARNING:** Removing a residual or parameter block will destroy - the implicit ordering, rendering the jacobian or residuals returned - from the solver uninterpretable. If you depend on the evaluated - jacobian, do not use remove! This may change in a future release. - Hold the indicated parameter block constant during optimization. - - .. function:: void Problem::SetParameterBlockConstant(double* values) Hold the indicated parameter block constant during optimization.