Changeset 682d86


Ignore:
Timestamp:
08/10/06 21:16:39 (7 years ago)
Author:
Tiago de Paula Peixoto <tiago@…>
Branches:
master, python3
Children:
0ef141
Parents:
53f38d
git-author:
Tiago de Paula Peixoto <tiago@…> (08/10/06 21:16:39)
git-committer:
Tiago de Paula Peixoto <tiago@…> (08/10/06 21:16:39)
Message:
average neighbour correlation must actually count neighbours twice, if double edges exist


git-svn-id: https://svn.forked.de/graph-tool/trunk@32 d4600afd-f417-0410-95de-beed9576f240
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/graph/graph_correlations_neighbours.cc

    r3412e2 r682d86  
    4949    { 
    5050    tr1::unordered_map<double,size_t> count; 
    51     tr1::unordered_set<typename graph_traits<Graph>::vertex_descriptor> neighbour_set; 
    5251 
    5352    typename graph_traits<Graph>::vertex_iterator v, v_begin, v_end; 
     
    5958        for(e = e_begin; e != e_end; ++e) 
    6059        {        
    61         if (neighbour_set.find(target(*e,g)) != neighbour_set.end()) 
    62             continue; 
    63         else 
    64             neighbour_set.insert(target(*e,g)); 
    6560        typename AvgDeg::value_type::second_type::first_type deg = _neighbours_degree(target(*e,g),g); 
    6661        typename AvgDeg::key_type orig_deg = _origin_degree(*v,g); 
     
    6964        count[orig_deg]++; 
    7065        } 
    71         neighbour_set.clear(); 
    7266    } 
    7367 
Note: See TracChangeset for help on using the changeset viewer.