Changeset 1015 for trunk/test


Ignore:
Timestamp:
Feb 1, 2008, 5:35:32 PM (14 years ago)
Author:
Peter
Message:

changing class names vectorView => VectorView? and vectorBase => VectorBase?. Refs #256

Location:
trunk/test
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/matrix_test.cc

    r1009 r1015  
    3636    : m_(i,j,value) {}
    3737
    38   inline theplu::yat::utility::vectorView
     38  inline theplu::yat::utility::VectorView
    3939  row(const size_t& i) { return m_.row_vec(i); }
    4040
     
    258258    for (size_t j=0; j<m5.columns(); ++j)
    259259      m5_sum2+=m5(i,j);
    260   utility::vectorView v5subrow(m5,3);
     260  utility::VectorView v5subrow(m5,3);
    261261  double v5subrow_sum=0;
    262262  for (size_t i=0; i<v5subrow.size(); ++i) {
     
    280280    for (size_t j=0; j<m5.columns(); ++j)
    281281      m5_sum3+=m5(i,j);
    282   utility::vectorView v5subcolumn = m5.column_vec(0);
     282  utility::VectorView v5subcolumn = m5.column_vec(0);
    283283  double v5subcolumn_sum=0;
    284284  for (size_t i=0; i<v5subcolumn.size(); ++i) {
     
    332332  *error << "\tthat class member returns a view" << std::endl;
    333333  matrixwrapper mw(5,2);
    334   utility::vectorView mwrow=mw.row(2);
     334  utility::VectorView mwrow=mw.row(2);
    335335  if (mwrow.gsl_vector_p()->data != &(mw.matrix()(2,0))) {
    336336    ok=false;
  • trunk/test/score_test.cc

    r1009 r1015  
    3232#include "yat/utility/matrix.h"
    3333#include "yat/utility/vector.h"
    34 #include "yat/utility/vectorView.h"
     34#include "yat/utility/VectorView.h"
    3535
    3636#include <cmath>
     
    9393  const double tol = 0.001;
    9494  for (size_t i=0; i<data.rows(); i++){
    95     utility::vectorView vec(data,i);
     95    utility::VectorView vec(data,i);
    9696    if (vec.size()!=target2.size()){
    9797      *error << "vec.size() is " << vec.size() << " and target2.size() is "
     
    109109  utility::vector weight(target2.size(),1);
    110110  for (size_t i=0; i<data.rows(); i++){
    111     utility::vectorView vec = data.row_vec(i);
     111    utility::VectorView vec = data.row_vec(i);
    112112    area = auc.score(target2, vec, weight);
    113113    if (area<correct_area(i)-tol || area>correct_area(i)+tol){
  • trunk/test/vector_test.cc

    r1009 r1015  
    2929#include "yat/utility/utility.h"
    3030#include "yat/utility/vector.h"
    31 #include "yat/utility/vectorView.h"
     31#include "yat/utility/VectorView.h"
    3232
    3333#include <fstream>
     
    7474  for (size_t i=0; i<vec.size(); i+=2)
    7575    sum_before+=vec[i];
    76   utility::vectorView vec_view(vec,0,6,2);
     76  utility::VectorView vec_view(vec,0,6,2);
    7777  sum_after=utility::sum(vec_view);
    7878  ok &= (sum_after==sum_before);
     
    8888    *message << "const view implementation" << std::endl;
    8989    const utility::vector vv(10,3.0);
    90     utility::vectorView vview(vv,0,5,1);
     90    utility::VectorView vview(vv,0,5,1);
    9191    // const utility::vector vview(vv,0,5,1); // this is the proper line
    9292    utility::vector vv2(5,2.0);
     
    148148    *message << "assignment operator on view" << std::endl;
    149149    vec[3]=vec[4]=vec[5]=13;
    150     utility::vectorView vec_view(vec,3,3,1);
     150    utility::VectorView vec_view(vec,3,3,1);
    151151    utility::vector vec2(3,123.0);
    152152    vec_view=vec2;
     
    173173      this_ok=false;
    174174    *message << "\tcloning vector view" << std::endl;
    175     utility::vectorView* vec_view=new utility::vectorView(vec,3,3,1);
    176     utility::vectorView vec_view2(*vec_view);
     175    utility::VectorView* vec_view=new utility::VectorView(vec,3,3,1);
     176    utility::VectorView vec_view2(*vec_view);
    177177    if (!vec_view2.isview())
    178178      this_ok=false;
Note: See TracChangeset for help on using the changeset viewer.