Turi Create
4.0
|
#include <toolkits/ml_data_2/data_storage/internal_metadata.hpp>
Public Member Functions | |
void | setup (bool is_target_column, const std::string &name, const std::shared_ptr< sarray< flexible_type > > &column, const std::map< std::string, ml_column_mode > &mode_overrides, const std::map< std::string, flexible_type > &options) |
void | set_training_index_size () |
bool | mode_has_fixed_size () const |
bool | is_untranslated_column () const |
size_t | index_size () const |
size_t | global_index_offset () const |
void | check_fixed_column_size (const flexible_type &v) const GL_HOT_INLINE_FLATTEN |
size_t | column_size () const |
void | save (turi::oarchive &oarc) const |
void | load (turi::iarchive &iarc) |
std::shared_ptr< column_metadata > | create_cleared_copy () const |
The metadata information for a single column. This is meant to be used internally to ml_data; there is no reason that the structures outside of ml_data need to access this; ml_metadata should be used instead.
This structure is necessary as many of the internal processing routines use a vector of column metadata to handle all the processing. Having this structure, which organizes all the parts of the column metadata into one place, greatly simplifies this processing.
Definition at line 34 of file internal_metadata.hpp.
|
inline |
During loading, we need to verify that the columns indeed have the correct column sizes.
Definition at line 199 of file internal_metadata.hpp.
|
inline |
Returns the current size of the column.
Definition at line 127 of file internal_metadata.hpp.
std::shared_ptr<column_metadata> turi::v2::ml_data_internal::column_metadata::create_cleared_copy | ( | ) | const |
Create a version of the metadata with all the indexing and statistics cleared.
|
inline |
Returns the size of the index at training time.
Definition at line 93 of file internal_metadata.hpp.
|
inline |
Returns the size of the index at training time.
Definition at line 86 of file internal_metadata.hpp.
|
inline |
Returns true if this column is untranslated and false otherwise.
Definition at line 80 of file internal_metadata.hpp.
void turi::v2::ml_data_internal::column_metadata::load | ( | turi::iarchive & | iarc | ) |
Serialization – load.
|
inline |
Returns true if the mode of this column has a fixed mode size and false otherwise.
Definition at line 70 of file internal_metadata.hpp.
void turi::v2::ml_data_internal::column_metadata::save | ( | turi::oarchive & | oarc | ) | const |
Serialization – save.
void turi::v2::ml_data_internal::column_metadata::set_training_index_size | ( | ) |
Finalize training.
void turi::v2::ml_data_internal::column_metadata::setup | ( | bool | is_target_column, |
const std::string & | name, | ||
const std::shared_ptr< sarray< flexible_type > > & | column, | ||
const std::map< std::string, ml_column_mode > & | mode_overrides, | ||
const std::map< std::string, flexible_type > & | options | ||
) |
Generates a new column_metadata class using the data arrays and the types.