Turi Create
4.0
|
#include <toolkits/ml_data_2/standardization-inl.hpp>
Public Member Functions | |
virtual | ~l2_rescaling () |
l2_rescaling (const std::shared_ptr< v2::ml_metadata > &ml_metadata, bool _use_reference=true) | |
void | transform (DenseVector &point) const |
void | transform (DenseMatrix &points) const |
void | inverse_transform (DenseVector &point) const |
void | inverse_transform (SparseVector &point) const |
void | transform (SparseVector &point) const |
void | save (turi::oarchive &oarc) const |
void | load (turi::iarchive &iarc) |
size_t | get_total_size () const |
Protected Attributes | |
DenseVector | scale |
bool | use_reference |
size_t | total_size |
Rescale columns by L2-norm x >= 0
Definition at line 202 of file standardization-inl.hpp.
|
inlinevirtual |
Default destructor.
Definition at line 215 of file standardization-inl.hpp.
|
inline |
Default constructor.
[in] | metadata | Metadata object for the features. |
[in] | index_size | Sizes of each of the features. |
[in] | use_reference | Reference encoding of categorical? |
Numeric : 1 String : # categories List : Size Categorical Vector : Total number of categories Dictionary : # keys
Definition at line 240 of file standardization-inl.hpp.
|
inlineinherited |
Return the total size of all the variables in the space.
[out] | total_size | Size of all the variables in the space. |
Numeric : 1 Categorical : # Unique categories Vector : Size of the vector. CategoricalVector : # Unique categories. Dictionary : # Keys
For reference encoding, subtract 1 from the Categorical and Categorical-Vector types.
Definition at line 190 of file standardization-inl.hpp.
|
inlinevirtual |
Inverse transform a point from the standardized space to the original space.
[in,out] | point(DenseVector) | Point to be transformed. |
Implements turi::standardization_interface.
Definition at line 379 of file standardization-inl.hpp.
|
inlinevirtual |
Inverse transform a point from the standardized space to the original space.
[in,out] | point(SparseVector) | Point to be transformed. |
Implements turi::standardization_interface.
Definition at line 393 of file standardization-inl.hpp.
|
inlinevirtual |
Serialization – Load object
Load this class from a Turi iarc object.
[in] | iarc | Turi iarc object |
Implements turi::standardization_interface.
Definition at line 432 of file standardization-inl.hpp.
|
inlinevirtual |
Serialization – Save object
Save this class to a Turi oarc object.
[in] | oarc | Turi oarc object |
Implements turi::standardization_interface.
Definition at line 420 of file standardization-inl.hpp.
|
inlinevirtual |
Transform a point from the original space to the standardized space.
[in,out] | point(DenseVector) | Point to be transformed. |
Implements turi::standardization_interface.
Definition at line 354 of file standardization-inl.hpp.
|
inline |
Transform a row of points from the original space to the standardized space.
[in,out] | point(DenseVector) | Point to be transformed. |
Definition at line 366 of file standardization-inl.hpp.
|
inlinevirtual |
Transform a point from the original space to the standardized space.
[in,out] | point(SparseVector) | Point to be transformed. |
Implements turi::standardization_interface.
Definition at line 407 of file standardization-inl.hpp.
|
protected |
Scale
Definition at line 206 of file standardization-inl.hpp.
|
protectedinherited |
Definition at line 98 of file standardization-inl.hpp.
|
protected |
Reference encoding
Definition at line 207 of file standardization-inl.hpp.