def normFlowDiff(G_data, G_estimate):
    """
    estimate the difference between the flows of two networks
    with identical network topology.

    Parameters
    ----------

    G_data: nx network with edge attribute "flow"
    G_estimate: nx network with edge attribute "flow"

    Returns
    -------
    a scalar representing the norm of the flows of two netorks

    """
    diff = sum([(G_data.get_edge_data(s,t)['flow'] - G_estimate.get_edge_data(s,t)['flow'])**2 for s,t in G_data.edges()])
    return diff