code: def _return_wrapper(fits, return_all, start, trace):
      """If the user wants to get all of the models back, this will
      return a list of the ARIMA models, otherwise it will just return
      the model. If this is called from the end of the function, ``fits``
      will already be a list.
  
      We *know* that if a function call makes it here, ``fits`` is NOT None
      or it would have thrown an exception in :func:`_post_ppc_arima`.
  
      Parameters
      ----------
      fits : iterable or ARIMA
          The ARIMA(s)
  
      return_all : bool
          Whether to return all.
      """
      # make sure it's an iterable
      if not is_iterable(fits):
          fits = [fits]
  
      # whether to print the final runtime
      if trace:
          print("Total fit time: %.3f seconds" % (time.time() - start))
  
      # which to return? if not all, then first index (assume sorted)
      if not return_all:
          return fits[0]
      return fits
  
imports: import numpy
  from sklearn.linear_model import LinearRegression
  import functools
  import time
  import warnings
  from ..base import BaseARIMA
  from .None import _doc
  from .None import _validation
  from .utils import ndiffs, is_constant, nsdiffs
  from ..utils import diff, is_iterable, check_endog
  from ..utils.metaestimators import if_has_delegate
  from ._context import AbstractContext, ContextType
  from .None import _auto_solvers
  from ..compat.numpy import DTYPE
  from ..compat import statsmodels
label_desc: Use image node_id 3 for calling a global function with example usage: _return_wrapper(fits, return_all, start, trace) and returns: fits, fits