code: def _get_datatype(info):
      """
      Gets datatype of BRIK file associated with HEAD file yielding `info`
  
      Parameters
      ----------
      info : dict
          As obtained by :func:`parse_AFNI_header`
  
      Returns
      -------
      dt : np.dtype
          Datatype of BRIK file associated with HEAD
  
      Notes
      -----
      ``BYTEORDER_STRING`` may be absent, signifying platform native byte order,
      or contain one of "LSB_FIRST" or "MSB_FIRST".
  
      ``BRICK_TYPES`` gives the storage data type for each sub-brick, with
      0=uint, 1=int16, 3=float32, 5=complex64 (see ``_dtype_dict``).  This should
      generally be the same value for each sub-brick in the dataset.
      """
      bo = info["BYTEORDER_STRING"]
      bt = info["BRICK_TYPES"]
      if isinstance(bt, list):
          if np.unique(bt).size > 1:
              raise AFNIImageError(
                  "Can't load file with multiple data types."
              )
          bt = bt[0]
      bo = _endian_dict.get(bo, "=")
      bt = _dtype_dict.get(bt, None)
      if bt is None:
          raise AFNIImageError("Can't deduce image data type.")
      return np.dtype(bo + bt)
  
imports: import os
  import re
  from copy import deepcopy
  import numpy
  from .arrayproxy import ArrayProxy
  from .fileslice import strided_scalar
  from .spatialimages import HeaderDataError, ImageDataError, SpatialHeader, SpatialImage
  from .volumeutils import Recoder
label_desc: Use image node_id 2 for calling a global function with example usage: _get_datatype(info) and returns: np