Changeset 797


Ignore:
Timestamp:
Mar 12, 2007, 11:53:38 PM (15 years ago)
Author:
Jari Häkkinen
Message:

Fixes #191. This is the best that can be done with the current design.

Location:
trunk/yat/utility
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/utility/WeNNI.cc

    r759 r797  
    5353  {
    5454    for (unsigned int i=0; i<data_.rows(); i++) {
    55       std::vector<std::pair<u_int,double> > distance=calculate_distances(i);
     55      std::vector<std::pair<u_int,double> > distance(calculate_distances(i));
    5656      std::sort(distance.begin(),distance.end(),
    5757                pair_value_compare<u_int,double>());
  • trunk/yat/utility/kNNI.cc

    r759 r797  
    5858  {
    5959    for (unsigned int i=0; i<mv_rows_.size(); i++) {
    60       std::vector<std::pair<u_int,double> > distance=
    61         calculate_distances(mv_rows_[i]);
     60      std::vector<std::pair<u_int,double> >
     61        distance(calculate_distances(mv_rows_[i]));
    6262      std::sort(distance.begin(),distance.end(),
    6363                pair_value_compare<u_int,double>());
Note: See TracChangeset for help on using the changeset viewer.