def check_not_i_within_i(antecedent_mention, mention):
    """
    Check whether one of the two mentions fully contains the other.

    "Not i-within-i", i.e.:
      the two mentions are not in an i-within-i constructs, that
      is, one cannot be a child NP in the other's NP constituent

    In this case, this is interpreted as "one mention does not
    fully contain the other"


    The following expression is equivalent to the one below

        not_i_within_i = not (
            (boffset2 <= boffset1 and eoffset1 <= eoffset2)
            or
            (boffset1 <= boffset2 and eoffset2 <= eoffset1)
        )

    This constraint is symmetric.

    :param antecedent_mention:  candidate antecedent Mention
    :param mention:     Mention under considerations
    """
    boffset1 = antecedent_mention.begin_offset
    eoffset1 = antecedent_mention.end_offset
    boffset2 = mention.begin_offset
    eoffset2 = mention.end_offset
    return (
        (boffset2 > boffset1 and eoffset2 > eoffset1)
        or
        (eoffset1 > eoffset2 and boffset1 > boffset2)
    )