| 114 | } |
| 115 | public: |
| 116 | DenseKernel(const MatrixXf & f, KernelType ktype, NormalizationType ntype):f_(f), ktype_(ktype), ntype_(ntype) { |
| 117 | if (ktype_ == DIAG_KERNEL) |
| 118 | parameters_ = VectorXf::Ones( f.rows() ); |
| 119 | else if( ktype == FULL_KERNEL ) |
| 120 | parameters_ = MatrixXf::Identity( f.rows(), f.rows() ); |
| 121 | initLattice( f ); |
| 122 | } |
| 123 | virtual void apply( MatrixXf & out, const MatrixXf & Q ) const { |
| 124 | filter( out, Q, false ); |
| 125 | } |