code: def close(self, other):
          
          if isinstance(other, QuaternionBase):
              return np.allclose(self.q, other.q) or np.allclose(self.q, -other.q)
          return NotImplemented
docs: Equality test with tolerance
          (same orientation, not necessarily same rotation)
  
  
          :param other: a QuaternionBase
          :returns: true if the quaternions are almost equal