<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def is_dtype_union_equal(source, target):
 """ Check whether two arrays have compatible dtypes to do a union. numpy types are checked with ``is_dtype_equal``. Extension types are checked separately. Parameters source : The first dtype to compare target : The second dtype to compare Returns boolean Whether or not the two dtypes are equal. True True False """

    source = _get_dtype(source)
    target = _get_dtype(target)
    if is_categorical_dtype(source) and is_categorical_dtype(target):
        # ordered False for both
        return source.ordered is target.ordered
    return is_dtype_equal(source, target)