def is_negatively_weighted(G, edge=None, weight='weight'):
    if edge is not None:
        data = G.get_edge_data(*edge)
        if data is None:
            msg = 'Edge {!r} does not exist.'.format(edge)
            raise nx.NetworkXError(msg)
        return weight in data and data[weight] < 0

    return any(weight in data and data[weight] < 0
               for u, v, data in G.edges(data=True))
Unbind an exchange from an exchange
dataset/ETHPy150Open networkx/networkx/networkx/classes/function.py/is_negatively_weighted--crossover with--dataset/ETHPy150Open veegee/amqpy/amqpy/channel.py/Channel.exchange_unbind