fitAlgs.boundFunc module¶
fitAlgs.boundFunc Module¶
Author: | Dominic Hunt |
---|
Functions¶
infBound ([base]) |
Boundary excess of inf when over bounds |
scalarBound ([base]) |
Boundary excess calculated as a scalar increase based on difference with bounds |
Author: | Dominic Hunt |
---|
-
fitAlgs.boundFunc.
infBound
(base=0)[source]¶ Boundary excess of
inf
when over boundsParameters: base (float, optional) – The cost at the boundary. Default 0 Returns: cost – Calculates the cost of exceeding the bounday using the parameters and the boundaries, and returns the cost. Return type: function Examples
>>> cst = infBound(base = 160) >>> cst([0.5, 2], [(0, 1), (0, 5)]) 160 >>> cst([0.5, 7], [(0, 1), (0, 5)]) inf
-
fitAlgs.boundFunc.
scalarBound
(base=0)[source]¶ Boundary excess calculated as a scalar increase based on difference with bounds
Parameters: base (float, optional) – The cost at the boundary. Default 0 Returns: cost – Calculates the cost of exceeding the boundary using the parameters and the boundaries, and returns the cost. Return type: function Examples
>>> cst = scalarBound(base=160) >>> cst([0.5, 2], [(0, 1), (0, 5)]) 160.0 >>> cst([0.5, 7], [(0, 1), (0, 5)]) 162.0