code: def border(
      labeled, i, j, Bc=None, out=None, always_return=True, output=None
  ):
      """
      border_img = border(labeled, i, j, Bc={3x3 cross}, out={np.zeros(labeled.shape, bool)}, always_return=True)
  
      Compute the border region between `i` and `j` regions.
  
      A pixel is on the border if it has value `i` (or `j`) and a pixel in its
      neighbourhood (defined by `Bc`) has value `j` (or `i`).
  
      Parameters
      ----------
      labeled : ndarray of integer type
          input labeled array
      i : integer
      j : integer
      Bc : structure element, optional
      out : ndarray of same shape as `labeled`, dtype=bool, optional
          where to store the output. If ``None``, a new array is allocated
      always_return : bool, optional
          if false, then, in the case where there is no pixel on the border,
          returns ``None``. Otherwise (the default), it always returns an array
          even if it is empty.
  
      Returns
      -------
      border_img : boolean ndarray
          Pixels are True exactly where there is a border between `i` and `j` in `labeled`
      """
      Bc = get_structuring_elem(labeled, Bc)
      output = _get_output(
          labeled, out, "labeled.border", bool, output=output
      )
      output.fill(False)
      return _labeled.border(
          labeled, Bc, output, i, j, bool(always_return)
      )
  
imports: from __future__ import division
  import numpy
  from .morph import get_structuring_elem
  from .None import _labeled
  from .internal import _get_output
  from ._filters import _checked_mode2int
  import mahotas
label_desc: Use image node_id 7 for calling a global function with example usage: border(labeled, i, j, Bc, out, always_return, output) and returns: _labeled