#include <Stack.h>
Definition at line 222 of file Stack.h.
◆ EmbeddingLayer()
lwtDev::EmbeddingLayer::EmbeddingLayer |
( |
int |
var_row_index, |
|
|
const MatrixXd & |
W |
|
) |
| |
Definition at line 427 of file Stack.cxx.
431 if(var_row_index < 0)
433 "EmbeddingLayer::EmbeddingLayer - can not set var_row_index<0,"
434 " it is an index for a matrix row!");
◆ ~EmbeddingLayer()
virtual lwtDev::EmbeddingLayer::~EmbeddingLayer |
( |
| ) |
|
|
inlinevirtual |
◆ scan()
MatrixXd lwtDev::EmbeddingLayer::scan |
( |
const MatrixXd & |
x | ) |
const |
|
overridevirtual |
Implements lwtDev::IRecurrentLayer.
Definition at line 437 of file Stack.cxx.
441 "EmbeddingLayer::scan - var_row_index is larger than input matrix"
444 MatrixXd embedded(
m_W.rows(),
x.cols());
448 bool is_int = std::floor(vector_idx) == vector_idx;
449 bool is_valid = (vector_idx >= 0) && (vector_idx <
m_W.cols());
452 embedded.col(
icol) =
m_W.col( vector_idx );
456 MatrixXd
out(
m_W.rows() + (
x.rows() - 1),
x.cols());
◆ m_go_backwards
bool lwtDev::IRecurrentLayer::m_go_backwards = false |
|
inherited |
◆ m_return_sequence
bool lwtDev::IRecurrentLayer::m_return_sequence = false |
|
inherited |
◆ m_var_row_index
int lwtDev::EmbeddingLayer::m_var_row_index |
|
private |
◆ m_W
MatrixXd lwtDev::EmbeddingLayer::m_W |
|
private |
The documentation for this class was generated from the following files: