code: def convert_dtypes(dtype_template, order_code):
      """Convert dtypes in mapping to given order
  
      Parameters
      ----------
      dtype_template : mapping
         mapping with values returning numpy dtype from ``np.dtype(val)``
      order_code : str
         an order code suitable for using in ``dtype.newbyteorder()``
  
      Returns
      -------
      dtypes : mapping
         mapping where values have been replaced by
         ``np.dtype(val).newbyteorder(order_code)``
  
      """
      dtypes = dtype_template.copy()
      for k in dtypes:
          dtypes[k] = np.dtype(dtypes[k]).newbyteorder(order_code)
      return dtypes
  
imports: import numpy
  from scipy._lib import doccer
  from .None import _byteordercodes
label_desc: Use image node_id 1 for calling a global function with example usage: convert_dtypes(dtype_template, order_code) and returns: dtypes