parameters: (options, A_ub, A_eq)
return_statement: return options, A_ub, A_eq
docstring: Check the provided ``A_ub`` and ``A_eq`` matrices conform to the specified
      optional sparsity variables.
  
      Parameters
      ----------
      A_ub : 2D array, optional
          2D array such that ``A_ub @ x`` gives the values of the upper-bound
          inequality constraints at ``x``.
      A_eq : 2D array, optional
          2D array such that ``A_eq @ x`` gives the values of the equality
          constraints at ``x``.
      options : dict
          A dictionary of solver options. All methods accept the following
          generic options:
  
              maxiter : int
                  Maximum number of iterations to perform.
              disp : bool
                  Set to True to print convergence messages.
  
          For method-specific options, see :func:`show_options('linprog')`.
  
      Returns
      -------
      A_ub : 2D array, optional
          2D array such that ``A_ub @ x`` gives the values of the upper-bound
          inequality constraints at ``x``.
      A_eq : 2D array, optional
          2D array such that ``A_eq @ x`` gives the values of the equality
          constraints at ``x``.
      options : dict
          A dictionary of solver options. All methods accept the following
          generic options:
  
              maxiter : int
                  Maximum number of iterations to perform.
              disp : bool
                  Set to True to print convergence messages.
  
          For method-specific options, see :func:`show_options('linprog')`.
docstring_summary: Check the provided ``A_ub`` and ``A_eq`` matrices conform to the specified
      optional sparsity variables.
docstring_tokens: Check the provided A_ub and A_eq matrices conform to the specified optional sparsity variables .
function: def _check_sparse_inputs(options, A_ub, A_eq):
      """
      Check the provided ``A_ub`` and ``A_eq`` matrices conform to the specified
      optional sparsity variables.
  
      Parameters
      ----------
      A_ub : 2D array, optional
          2D array such that ``A_ub @ x`` gives the values of the upper-bound
          inequality constraints at ``x``.
      A_eq : 2D array, optional
          2D array such that ``A_eq @ x`` gives the values of the equality
          constraints at ``x``.
      options : dict
          A dictionary of solver options. All methods accept the following
          generic options:
  
              maxiter : int
                  Maximum number of iterations to perform.
              disp : bool
                  Set to True to print convergence messages.
  
          For method-specific options, see :func:`show_options('linprog')`.
  
      Returns
      -------
      A_ub : 2D array, optional
          2D array such that ``A_ub @ x`` gives the values of the upper-bound
          inequality constraints at ``x``.
      A_eq : 2D array, optional
          2D array such that ``A_eq @ x`` gives the values of the equality
          constraints at ``x``.
      options : dict
          A dictionary of solver options. All methods accept the following
          generic options:
  
              maxiter : int
                  Maximum number of iterations to perform.
              disp : bool
                  Set to True to print convergence messages.
  
          For method-specific options, see :func:`show_options('linprog')`.
      """
      # This is an undocumented option for unit testing sparse presolve
      _sparse_presolve = options.pop('_sparse_presolve', False)
      if _sparse_presolve and A_eq is not None:
          A_eq = sps.coo_matrix(A_eq)
      if _sparse_presolve and A_ub is not None:
          A_ub = sps.coo_matrix(A_ub)
  
      sparse = options.get('sparse', False)
      if not sparse and (sps.issparse(A_eq) or sps.issparse(A_ub)):
          options['sparse'] = True
          warn("Sparse constraint matrix detected; setting 'sparse':True.",
                  OptimizeWarning)
      return options, A_ub, A_eq
function_tokens: def _check_sparse_inputs ( options , A_ub , A_eq ) : # This is an undocumented option for unit testing sparse presolve _sparse_presolve = options . pop ( '_sparse_presolve' , False ) if _sparse_presolve and A_eq is not None : A_eq = sps . coo_matrix ( A_eq ) if _sparse_presolve and A_ub is not None : A_ub = sps . coo_matrix ( A_ub ) sparse = options . get ( 'sparse' , False ) if not sparse and ( sps . issparse ( A_eq ) or sps . issparse ( A_ub ) ) : options [ 'sparse' ] = True warn ( "Sparse constraint matrix detected; setting 'sparse':True." , OptimizeWarning ) return options , A_ub , A_eq