parameters: (bounds)
return_statement: return lb, ub
docstring: Convert the old bounds representation to the new one.
  
      The new representation is a tuple (lb, ub) and the old one is a list
      containing n tuples, i-th containing lower and upper bound on a i-th
      variable.
docstring_summary: Convert the old bounds representation to the new one.
docstring_tokens: Convert the old bounds representation to the new one .
function: def old_bound_to_new(bounds):
      """Convert the old bounds representation to the new one.
  
      The new representation is a tuple (lb, ub) and the old one is a list
      containing n tuples, i-th containing lower and upper bound on a i-th
      variable.
      """
      lb, ub = zip(*bounds)
      lb = np.array([x if x is not None else -np.inf for x in lb])
      ub = np.array([x if x is not None else np.inf for x in ub])
      return lb, ub
function_tokens: def old_bound_to_new ( bounds ) : lb , ub = zip ( * bounds ) lb = np . array ( [ x if x is not None else - np . inf for x in lb ] ) ub = np . array ( [ x if x is not None else np . inf for x in ub ] ) return lb , ub