parameters: (self)
return_statement: return types.Array(dtype, self.ndim, layout)
docstring: Magic attribute expected by Numba to get the numba type that
          represents this object.
docstring_summary: Magic attribute expected by Numba to get the numba type that
          represents this object.
docstring_tokens: Magic attribute expected by Numba to get the numba type that represents this object .
function: def _numba_type_(self):
          """
          Magic attribute expected by Numba to get the numba type that
          represents this object.
          """
          # Typing considerations:
          #
          # 1. The preference is to use 'C' or 'F' layout since this enables
          # hardcoding stride values into compiled kernels, which is more
          # efficient than storing a passed-in value in a register.
          #
          # 2. If an array is both C- and F-contiguous, prefer 'C' layout as it's
          # the more likely / common case.
          #
          # 3. If an array is broadcast then it must be typed as 'A' - using 'C'
          # or 'F' does not apply for broadcast arrays, because the strides, some
          # of which will be 0, will not match those hardcoded in for 'C' or 'F'
          # layouts.
  
          broadcast = 0 in self.strides
          if self.flags['C_CONTIGUOUS'] and not broadcast:
              layout = 'C'
          elif self.flags['F_CONTIGUOUS'] and not broadcast:
              layout = 'F'
          else:
              layout = 'A'
  
          dtype = numpy_support.from_dtype(self.dtype)
          return types.Array(dtype, self.ndim, layout)
function_tokens: def _numba_type_ ( self ) : # Typing considerations: # # 1. The preference is to use 'C' or 'F' layout since this enables # hardcoding stride values into compiled kernels, which is more # efficient than storing a passed-in value in a register. # # 2. If an array is both C- and F-contiguous, prefer 'C' layout as it's # the more likely / common case. # # 3. If an array is broadcast then it must be typed as 'A' - using 'C' # or 'F' does not apply for broadcast arrays, because the strides, some # of which will be 0, will not match those hardcoded in for 'C' or 'F' # layouts. broadcast = 0 in self . strides if self . flags [ 'C_CONTIGUOUS' ] and not broadcast : layout = 'C' elif self . flags [ 'F_CONTIGUOUS' ] and not broadcast : layout = 'F' else : layout = 'A' dtype = numpy_support . from_dtype ( self . dtype ) return types . Array ( dtype , self . ndim , layout )