Skylark (Sketching Library)
0.1
|
00001 #ifndef SKYLARK_PPT_HPP 00002 #define SKYLARK_PPT_HPP 00003 00004 #ifndef SKYLARK_SKETCH_HPP 00005 #error "Include top-level sketch.hpp instead of including individuals headers" 00006 #endif 00007 00008 namespace skylark { namespace sketch { 00009 00010 template < typename InputMatrixType, 00011 typename OutputMatrixType = InputMatrixType > 00012 struct PPT_t : 00013 public PPT_data_t, 00014 virtual public sketch_transform_t<InputMatrixType, OutputMatrixType > { 00015 // To be specilized and derived. Just some guards here. 00016 typedef InputMatrixType matrix_type; 00017 typedef OutputMatrixType output_matrix_type; 00018 00019 typedef PPT_data_t data_type; 00020 typedef data_type::params_t params_t; 00021 00022 PPT_t(int N, int S, int q, double c, double gamma, 00023 base::context_t& context) : 00024 data_type(N, S, q, c, gamma, context) { 00025 SKYLARK_THROW_EXCEPTION ( 00026 base::sketch_exception() 00027 << base::error_msg( 00028 "This combination has not yet been implemented for PPT")); 00029 } 00030 00031 PPT_t(int N, int S, const params_t& params, base::context_t& context) : 00032 data_type(N, S, params, context) { 00033 SKYLARK_THROW_EXCEPTION ( 00034 base::sketch_exception() 00035 << base::error_msg( 00036 "This combination has not yet been implemented for PPT")); 00037 } 00038 00039 PPT_t(const data_type& other_data) 00040 : data_type(other_data) { 00041 SKYLARK_THROW_EXCEPTION ( 00042 base::sketch_exception() 00043 << base::error_msg( 00044 "This combination has not yet been implemented for PPT")); 00045 } 00046 PPT_t(const boost::property_tree::ptree &pt) 00047 : data_type(pt) { 00048 SKYLARK_THROW_EXCEPTION ( 00049 base::sketch_exception() 00050 << base::error_msg( 00051 "This combination has not yet been implemented for PPT")); 00052 } 00053 00054 void apply (const matrix_type& A, 00055 output_matrix_type& sketch_of_A, 00056 columnwise_tag dimension) const { 00057 SKYLARK_THROW_EXCEPTION ( 00058 base::sketch_exception() 00059 << base::error_msg( 00060 "This combination has not yet been implemented for PPT")); 00061 } 00062 00063 void apply (const matrix_type& A, 00064 output_matrix_type& sketch_of_A, 00065 rowwise_tag dimension) const { 00066 SKYLARK_THROW_EXCEPTION ( 00067 base::sketch_exception() 00068 << base::error_msg( 00069 "This combination has not yet been implemented for PPT")); 00070 } 00071 00072 int get_N() const { return this->_N; } 00073 int get_S() const { return this->_S; } 00075 const sketch_transform_data_t* get_data() const { return this; } 00076 }; 00077 00078 } } 00080 #if SKYLARK_HAVE_ELEMENTAL 00081 # include "PPT_Elemental.hpp" 00082 #endif 00083 00084 #endif // SKYLARK_PPT_HPP