Skylark (Sketching Library)
0.1
|
#include <CWT.hpp>
Public Types | |
typedef hash_transform_t < InputMatrixType, OutputMatrixType, boost::random::uniform_int_distribution, utility::rademacher_distribution_t > | transform_t |
typedef CWT_data_t | data_type |
typedef data_type::params_t | params_t |
Public Member Functions | |
CWT_t (int N, int S, base::context_t &context) | |
CWT_t (int N, int S, const params_t ¶ms, base::context_t &context) | |
CWT_t (const boost::property_tree::ptree &pt) | |
template<typename OtherInputMatrixType , typename OtherOutputMatrixType > | |
CWT_t (const CWT_t< OtherInputMatrixType, OtherOutputMatrixType > &other) | |
CWT_t (const data_type &other) | |
void | apply (const typename transform_t::matrix_type &A, typename transform_t::output_matrix_type &sketch_of_A, columnwise_tag dimension) const |
void | apply (const typename transform_t::matrix_type &A, typename transform_t::output_matrix_type &sketch_of_A, rowwise_tag dimension) const |
int | get_N () const |
int | get_S () const |
const sketch_transform_data_t * | get_data () const |
Clarkson-Woodruff Transform
Clarkson-Woodruff Transform is essentially the CountSketch sketching originally suggested by Charikar et al. Analysis by Clarkson and Woodruff in STOC 2013 shows that this is sketching scheme can be used to build a subspace embedding. c CWT was additionally analyzed by Meng and Mahoney (STOC'13) and is equivalent to OSNAP with s=1.
typedef CWT_data_t skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::data_type |
typedef data_type::params_t skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::params_t |
typedef hash_transform_t<InputMatrixType, OutputMatrixType, boost::random::uniform_int_distribution, utility::rademacher_distribution_t> skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::transform_t |
skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::CWT_t | ( | int | N, |
int | S, | ||
base::context_t & | context | ||
) | [inline] |
skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::CWT_t | ( | int | N, |
int | S, | ||
const params_t & | params, | ||
base::context_t & | context | ||
) | [inline] |
skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::CWT_t | ( | const boost::property_tree::ptree & | pt | ) | [inline] |
skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::CWT_t | ( | const CWT_t< OtherInputMatrixType, OtherOutputMatrixType > & | other | ) | [inline] |
skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::CWT_t | ( | const data_type & | other | ) | [inline] |
void skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::apply | ( | const typename transform_t::matrix_type & | A, |
typename transform_t::output_matrix_type & | sketch_of_A, | ||
columnwise_tag | dimension | ||
) | const [inline] |
Apply columnwise the sketching transform that is described by the the transform with output sketch_of_A.
Definition at line 69 of file CWT.hpp.
Referenced by main(), and test_main().
void skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::apply | ( | const typename transform_t::matrix_type & | A, |
typename transform_t::output_matrix_type & | sketch_of_A, | ||
rowwise_tag | dimension | ||
) | const [inline] |
const sketch_transform_data_t* skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::get_data | ( | ) | const [inline, virtual] |
Implements skylark::sketch::sketch_transform_t< InputMatrixType, OutputMatrixType >.
Definition at line 88 of file CWT.hpp.
Referenced by test_main().
int skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::get_N | ( | ) | const [inline, virtual] |
Get input dimesion.
Implements skylark::sketch::sketch_transform_t< InputMatrixType, OutputMatrixType >.
Definition at line 85 of file CWT.hpp.
References skylark::sketch::sketch_transform_data_t::_N.
int skylark::sketch::CWT_t< InputMatrixType, OutputMatrixType >::get_S | ( | ) | const [inline, virtual] |
Get output dimesion.
Implements skylark::sketch::sketch_transform_t< InputMatrixType, OutputMatrixType >.
Definition at line 86 of file CWT.hpp.
References skylark::sketch::sketch_transform_data_t::_S.