void TearDown()
 {
     delete[] data_.ptr();
     delete[] query_.ptr();
     delete[] match_.ptr();
     delete[] dists_.ptr();
     delete[] indices_.ptr();
 }
Exemplo n.º 2
0
 void TearDown()
 {
     delete[] data.ptr();
     delete[] query.ptr();
     delete[] match.ptr();
     delete[] dists.ptr();
     delete[] indices.ptr();
 }
Exemplo n.º 3
0
 void serialize(Archive& ar, const unsigned int version) {
     ar & indices.rows;
     ar & indices.cols;
     if (Archive::is_loading::value) {
         indices.data = new int[indices.rows*indices.cols];
     }
     ar & boost::serialization::make_array(indices.data, indices.rows*indices.cols);
     if (Archive::is_saving::value) {
         indices.free();
     }
     ar & dists.rows;
     ar & dists.cols;
     if (Archive::is_loading::value) {
         dists.data = new DistanceType[dists.rows*dists.cols];
     }
     ar & boost::serialization::make_array(dists.data, dists.rows*dists.cols);
     if (Archive::is_saving::value) {
         dists.free();
     }
 }
 void TearDown()
 {
     delete[] data_.ptr();
     delete[] query_.ptr();
     delete[] dists_single_.ptr();
     delete[] indices_single_.ptr();
     delete[] dists_multi_.ptr();
     delete[] indices_multi_.ptr();
 }
Exemplo n.º 5
0
 void TearDown()
 {
     delete[] data.ptr();
     delete[] query.ptr();
     delete[] dists_single.ptr();
     delete[] indices_single.ptr();
     delete[] dists_multi.ptr();
     delete[] indices_multi.ptr();
 }