algolib 包

子包

子模块

algolib.exceptions 模块

Centralized exception hierarchy for algolib.

  • Keep backward compatibility with existing exceptions: - AlgolibError - InvalidTypeError - InvalidValueError

  • Add more specific exceptions grouped by area (args/dimension, algebra, geometry, numeric/convergence, feature support).

exception algolib.exceptions.AlgolibError[源代码]

基类:Exception

此库的基础异常类。

exception algolib.exceptions.AmbiguousGeometryError[源代码]

基类:AlgolibError

Constraints are insufficient or solution is not unique.

exception algolib.exceptions.ConvergenceError(iterations: int, residual: float | None = None, target_tol: float | None = None)[源代码]

基类:AlgolibError

Iteration did not converge within budget/tolerance.

iterations: int
residual: float | None = None
target_tol: float | None = None
exception algolib.exceptions.DegeneracyError[源代码]

基类:AlgolibError

Degenerate configuration (e.g., zero-length direction, collinear).

exception algolib.exceptions.DimensionMismatchError(expected: Any, got: Any, message: str | None = None)[源代码]

基类:AlgolibError

Incompatible shapes/dimensions.

exception algolib.exceptions.InvalidTypeError[源代码]

基类:AlgolibError, TypeError

当参数类型无效时引发。

exception algolib.exceptions.InvalidValueError[源代码]

基类:AlgolibError, ValueError

当参数值无效时引发。

exception algolib.exceptions.LossOfSignificanceError[源代码]

基类:AlgolibError

Severe cancellation/rounding made the result unreliable.

exception algolib.exceptions.NoIntersectionError[源代码]

基类:AlgolibError

No intersection between geometric entities.

exception algolib.exceptions.NotImplementedAlgolibError[源代码]

基类:AlgolibError, NotImplementedError

Public API declared but not implemented yet.

exception algolib.exceptions.NotPositiveDefiniteError[源代码]

基类:AlgolibError

Matrix expected to be (strictly) positive-definite.

exception algolib.exceptions.NotSupportedError[源代码]

基类:AlgolibError

Feature not supported in this backend/type/platform.

exception algolib.exceptions.NumericOverflowError[源代码]

基类:AlgolibError, OverflowError

Numeric overflow exposed as algolib-specific error.

exception algolib.exceptions.NumericUnderflowError[源代码]

基类:AlgolibError

Numeric underflow to zero/denormals that invalidates the result.

exception algolib.exceptions.SingularMatrixError[源代码]

基类:AlgolibError

Matrix is singular / not invertible.

exception algolib.exceptions.ToleranceError[源代码]

基类:AlgolibError, AssertionError

An expected property did not hold within tolerance.

模块内容