00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00030 #include "describe.h"
00031
00033
00036 string describe( ConstTensor7View x )
00037 {
00038 ostringstream os;
00039 os << "Tensor7 ["
00040 << x.nlibraries() << ","
00041 << x.nvitrines() << ","
00042 << x.nshelves() << ","
00043 << x.nbooks() << ","
00044 << x.npages() << ","
00045 << x.nrows() << ","
00046 << x.ncols() << "]";
00047 return os.str();
00048 }
00049
00051
00054 string describe( ConstTensor6View x )
00055 {
00056 ostringstream os;
00057 os << "Tensor6 ["
00058 << x.nvitrines() << ","
00059 << x.nshelves() << ","
00060 << x.nbooks() << ","
00061 << x.npages() << ","
00062 << x.nrows() << ","
00063 << x.ncols() << "]";
00064 return os.str();
00065 }
00066
00068
00071 string describe( ConstTensor5View x )
00072 {
00073 ostringstream os;
00074 os << "Tensor5 ["
00075 << x.nshelves() << ","
00076 << x.nbooks() << ","
00077 << x.npages() << ","
00078 << x.nrows() << ","
00079 << x.ncols() << "]";
00080 return os.str();
00081 }
00082
00084
00087 string describe( ConstTensor4View x )
00088 {
00089 ostringstream os;
00090 os << "Tensor4 ["
00091 << x.nbooks() << ","
00092 << x.npages() << ","
00093 << x.nrows() << ","
00094 << x.ncols() << "]";
00095 return os.str();
00096 }
00097
00099
00102 string describe( ConstTensor3View x )
00103 {
00104 ostringstream os;
00105 os << "Tensor3 ["
00106 << x.npages() << ","
00107 << x.nrows() << ","
00108 << x.ncols() << "]";
00109 return os.str();
00110 }
00111
00113
00116 string describe( ConstMatrixView x )
00117 {
00118 ostringstream os;
00119 os << "Matrix ["
00120 << x.nrows() << ","
00121 << x.ncols() << "]";
00122 return os.str();
00123 }
00124
00126
00129 string describe( ConstVectorView x )
00130 {
00131 ostringstream os;
00132 os << "Vector ["
00133 << x.nelem() << "]";
00134 return os.str();
00135 }
00136
00138
00141 string describe( const Numeric& x )
00142 {
00143 ostringstream os;
00144 os << "Scalar (" << x << ")";
00145 return os.str();
00146 }