x3cflux.run_optimization

class x3cflux.run_optimization(simulator, starting_point: ndarray, bounds: Dict[str, Tuple[float, float]] | None = None, **kwargs)

Bases:

Run optimization from given starting point.

Optimization uses the interior point optimizer ipopt and its Python interface cyipopt. ipopt can be configured by passing the appropriate kwargs. See A. Wächter and L. T. Biegler (2006), https://link.springer.com/article/10.1007/s10107-004-0559-y.

Parameters:
  • simulator (Simulator) – Labeling simulator to evaluate the SSR and its gradient

  • starting_point (numpy.ndarray) – Starting point/initial guess of metabolic parameters. Shape has to be either (N,) or (N, 1) with N being the number of metabolic parameters

  • bounds (dict[str, tuple[float, float]], optional) – Parameter boundary constraints

  • **kwargs – Options passed to ipopt. See https://coin-or.github.io/Ipopt/OPTIONS.html.

Returns:

  • numpy.ndarray – Optimal parameters

  • float – SSR value at the local optimum