#include <keras_model.h>
Definition at line 55 of file keras_model.h.
keras::DataChunk2D::DataChunk2D |
( |
size_t |
depth, |
|
|
size_t |
rows, |
|
|
size_t |
cols, |
|
|
float |
init |
|
) |
| |
|
inline |
Definition at line 57 of file keras_model.h.
std::vector< std::vector< std::vector< float > > > data
keras::DataChunk2D::DataChunk2D |
( |
void |
| ) |
|
|
inline |
Definition at line 62 of file keras_model.h.
std::vector< std::vector< std::vector< float > > > data
size_t keras::DataChunk2D::get_data_dim |
( |
void |
| ) |
const |
|
inlinevirtual |
void keras::DataChunk2D::read_from_file |
( |
const std::string & |
fname | ) |
|
|
virtual |
Reimplemented from keras::DataChunk.
Definition at line 24 of file keras_model.cc.
25 ifstream fin(
fname.c_str());
29 vector<vector<float> > tmp_single_depth;
32 tmp_single_depth.push_back(tmp_row);
34 data.push_back(tmp_single_depth);
std::vector< std::vector< std::vector< float > > > data
std::vector< float > read_1d_array(std::ifstream &fin, int cols)
void keras::DataChunk2D::show_name |
( |
| ) |
|
|
inlinevirtual |
Implements keras::DataChunk.
Definition at line 67 of file keras_model.h.
68 std::cout <<
"DataChunk2D " <<
data.size() <<
"x" <<
data[0].size() <<
"x" <<
data[0][0].size() <<
std::endl;
std::vector< std::vector< std::vector< float > > > data
QTextStream & endl(QTextStream &s)
void keras::DataChunk2D::show_values |
( |
| ) |
|
|
inlinevirtual |
Implements keras::DataChunk.
Definition at line 71 of file keras_model.h.
72 std::cout <<
"DataChunk2D values:" <<
std::endl;
73 for(
size_t i = 0; i <
data.size(); ++i) {
75 for(
size_t j = 0; j <
data[0].size(); ++j) {
76 for(
size_t k = 0;
k <
data[0][0].size(); ++
k) {
77 std::cout <<
data[i][j][
k] <<
" ";
std::vector< std::vector< std::vector< float > > > data
QTextStream & endl(QTextStream &s)
int keras::DataChunk2D::m_cols |
int keras::DataChunk2D::m_depth |
int keras::DataChunk2D::m_rows |
The documentation for this class was generated from the following files: