class_docstr: Wrapper for scipy.optimize.minimize.
  
  Only `jac` differs from scipy: if `autodiff`, then
  `gs.autodiff.value_and_grad` is used to compute the jacobian.
docstr: Minimize objective function.
  
  Parameters
  ----------
  fun : callable
      The objective function to be minimized.
  x0 : array-like
      Initial guess.
  fun_jac : callable
      If not None, jac is ignored.
  fun_hess : callable
      If not None, hess is ignored.
  hessp : callable
code: def minimize(self, fun, x0, fun_jac=None, fun_hess=None, hessp=None):
      """Minimize objective function.
  
      Parameters
      ----------
      fun : callable
          The objective function to be minimized.
      x0 : array-like
          Initial guess.
      fun_jac : callable
          If not None, jac is ignored.
      fun_hess : callable
          If not None, hess is ignored.
      hessp : callable
      """
      fun_, jac = self._handle_jac(fun, fun_jac)
      hess = self._handle_hess(fun_hess)
  
      result = scipy.optimize.minimize(
          fun_,
          x0,
          method=self.method,
          jac=jac,
          hess=hess,
          hessp=hessp,
          bounds=self.bounds,
          tol=self.tol,
          constraints=self.constraints,
          callback=self.callback,
          options=self.options,
      )
  
      result = result_to_backend_type(result)
  
      if result.status > 0:
          logging.warning(result.message)
  
      if self.save_result:
          self.result_ = result
  
      return result
  
file_path: geomstats/geomstats/numerics/optimizers.py
imports: import logging
  import scipy
  import geomstats.backend
  from geomstats.numerics._common import result_to_backend_type
label_desc: Use image node_id 4 for calling the ScipyMinimize obj's underlying member method code with example usage: obj.minimize(fun, x0, fun_jac, fun_hess, hessp) and returns: result