Convolutional1dComponent implements convolution over frequency axis. More...
#include <nnet-component.h>
Public Member Functions | |
Convolutional1dComponent () | |
Convolutional1dComponent (const Convolutional1dComponent &component) | |
Convolutional1dComponent (const CuMatrixBase< BaseFloat > &filter_params, const CuVectorBase< BaseFloat > &bias_params, BaseFloat learning_rate) | |
int32 | InputDim () const |
Get size of input vectors. More... | |
int32 | OutputDim () const |
Get size of output vectors. More... | |
void | Init (BaseFloat learning_rate, int32 input_dim, int32 output_dim, int32 patch_dim, int32 patch_step, int32 patch_stride, BaseFloat param_stddev, BaseFloat bias_stddev, bool appended_conv) |
void | Init (BaseFloat learning_rate, int32 patch_dim, int32 patch_step, int32 patch_stride, std::string matrix_filename, bool appended_conv) |
void | Resize (int32 input_dim, int32 output_dim) |
std::string | Info () const |
void | InitFromString (std::string args) |
Initialize, typically from a line of a config file. More... | |
std::string | Type () const |
bool | BackpropNeedsInput () const |
bool | BackpropNeedsOutput () const |
void | Propagate (const ChunkInfo &in_info, const ChunkInfo &out_info, const CuMatrixBase< BaseFloat > &in, CuMatrixBase< BaseFloat > *out) const |
Perform forward pass propagation Input->Output. More... | |
void | Scale (BaseFloat scale) |
This new virtual function scales the parameters by this amount. More... | |
virtual void | Add (BaseFloat alpha, const UpdatableComponent &other) |
This new virtual function adds the parameters of another updatable component, times some constant, to the current parameters. More... | |
virtual void | Backprop (const ChunkInfo &in_info, const ChunkInfo &out_info, const CuMatrixBase< BaseFloat > &in_value, const CuMatrixBase< BaseFloat > &out_value, const CuMatrixBase< BaseFloat > &out_deriv, Component *to_update_in, CuMatrix< BaseFloat > *in_deriv) const |
Perform backward pass propagation of the derivative, and also either update the model (if to_update == this) or update another model or compute the model derivative (otherwise). More... | |
void | SetZero (bool treat_as_gradient) |
Set parameters to zero, and if treat_as_gradient is true, we'll be treating this as a gradient so set the learning rate to 1 and make any other changes necessary (there's a variable we have to set for the MixtureProbComponent). More... | |
void | Read (std::istream &is, bool binary) |
void | Write (std::ostream &os, bool binary) const |
Write component to stream. More... | |
virtual BaseFloat | DotProduct (const UpdatableComponent &other) const |
Here, "other" is a component of the same specific type. More... | |
Component * | Copy () const |
Copy component (deep copy). More... | |
void | PerturbParams (BaseFloat stddev) |
We introduce a new virtual function that only applies to class UpdatableComponent. More... | |
void | SetParams (const VectorBase< BaseFloat > &bias, const MatrixBase< BaseFloat > &filter) |
const CuVector< BaseFloat > & | BiasParams () |
const CuMatrix< BaseFloat > & | LinearParams () |
int32 | GetParameterDim () const |
The following new virtual function returns the total dimension of the parameters in this class. More... | |
void | Update (const CuMatrixBase< BaseFloat > &in_value, const CuMatrixBase< BaseFloat > &out_deriv) |
Public Member Functions inherited from UpdatableComponent | |
UpdatableComponent (const UpdatableComponent &other) | |
void | Init (BaseFloat learning_rate) |
UpdatableComponent (BaseFloat learning_rate) | |
UpdatableComponent () | |
virtual | ~UpdatableComponent () |
void | SetLearningRate (BaseFloat lrate) |
Sets the learning rate of gradient descent. More... | |
BaseFloat | LearningRate () const |
Gets the learning rate of gradient descent. More... | |
virtual void | Vectorize (VectorBase< BaseFloat > *params) const |
Turns the parameters into vector form. More... | |
virtual void | UnVectorize (const VectorBase< BaseFloat > ¶ms) |
Converts the parameters from vector form. More... | |
Public Member Functions inherited from Component | |
Component () | |
virtual int32 | Index () const |
Returns the index in the sequence of layers in the neural net; intended only to be used in debugging information. More... | |
virtual void | SetIndex (int32 index) |
virtual std::vector< int32 > | Context () const |
Return a vector describing the temporal context this component requires for each frame of output, as a sorted list. More... | |
void | Propagate (const ChunkInfo &in_info, const ChunkInfo &out_info, const CuMatrixBase< BaseFloat > &in, CuMatrix< BaseFloat > *out) const |
A non-virtual propagate function that first resizes output if necessary. More... | |
virtual | ~Component () |
Private Member Functions | |
const Convolutional1dComponent & | operator= (const Convolutional1dComponent &other) |
Static Private Member Functions | |
static void | ReverseIndexes (const std::vector< int32 > &forward_indexes, int32 input_dim, std::vector< std::vector< int32 > > *backward_indexes) |
static void | RearrangeIndexes (const std::vector< std::vector< int32 > > &in, std::vector< std::vector< int32 > > *out) |
Private Attributes | |
int32 | patch_dim_ |
int32 | patch_step_ |
int32 | patch_stride_ |
CuMatrix< BaseFloat > | filter_params_ |
CuVector< BaseFloat > | bias_params_ |
bool | appended_conv_ |
bool | is_gradient_ |
Additional Inherited Members | |
Static Public Member Functions inherited from Component | |
static Component * | ReadNew (std::istream &is, bool binary) |
Read component from stream. More... | |
static Component * | NewFromString (const std::string &initializer_line) |
Initialize the Component from one line that will contain first the type, e.g. More... | |
static Component * | NewComponentOfType (const std::string &type) |
Return a new Component of the given type e.g. More... | |
Protected Attributes inherited from UpdatableComponent | |
BaseFloat | learning_rate_ |
learning rate (0.0..0.01) More... | |
Convolutional1dComponent implements convolution over frequency axis.
We assume the input featrues are spliced, i.e. each frame is in fact a set of stacked frames, where we can form patches which span over several frequency bands and whole time axis. A patch is the instance of a filter on a group of frequency bands and whole time axis. Shifts of the filter generate patches.
The convolution is done over whole axis with same filter coefficients, i.e. we don't use separate filters for different 'regions' of frequency axis. Due to convolution, same weights are used repeateadly, the final gradient is a sum of all position-specific gradients (the sum was found better than averaging).
In order to have a fast implementations, the filters are represented in vectorized form, where each rectangular filter corresponds to a row in a matrix, where all the filters are stored. The features are then re-shaped to a set of matrices, where one matrix corresponds to single patch-position, where all the filters get applied.
The type of convolution is controled by hyperparameters: patch_dim_ ... frequency axis size of the patch patch_step_ ... size of shift in the convolution patch_stride_ ... shift for 2nd dim of a patch (i.e. frame length before splicing) For instance, for a convolutional component after raw input, if the input is 36-dim fbank feature with delta of order 2 and spliced using +/- 5 frames of contexts, the convolutional component takes the input as a 36 x 33 image. The patch_stride_ should be configured 36. If patch_step_ and patch_dim_ are configured 1 and 7, the Convolutional1dComponent creates a 2D filter of 7 x 33, such that the convolution is actually done only along the frequency axis. Specifically, the convolutional output along the frequency axis is (36 - 7) / 1 + 1 = 30, and the convolutional output along the temporal axis is 33 - 33 + 1 = 1, resulting in an output image of 30 x 1, which is called a feature map in ConvNet. Then if the output-dim is set 3840, the constructor would know there should be 3840 / 30 = 128 distinct filters, which will create 128 feature maps of 30 x 1 for one frame of input. The feature maps are vectorized as a 3840-dim row vector in the output matrix of this component. For details on progatation of Convolutional1dComponent, check the function definition.
Definition at line 1718 of file nnet-component.h.
Definition at line 3630 of file nnet-component.cc.
Referenced by Convolutional1dComponent::Copy().
Convolutional1dComponent | ( | const Convolutional1dComponent & | component | ) |
Definition at line 3635 of file nnet-component.cc.
Convolutional1dComponent | ( | const CuMatrixBase< BaseFloat > & | filter_params, |
const CuVectorBase< BaseFloat > & | bias_params, | ||
BaseFloat | learning_rate | ||
) |
Definition at line 3642 of file nnet-component.cc.
References Convolutional1dComponent::appended_conv_, CuVectorBase< Real >::Dim(), Convolutional1dComponent::is_gradient_, KALDI_ASSERT, and CuMatrixBase< Real >::NumRows().
|
virtual |
This new virtual function adds the parameters of another updatable component, times some constant, to the current parameters.
Implements UpdatableComponent.
Definition at line 3900 of file nnet-component.cc.
References Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, and KALDI_ASSERT.
|
virtual |
Perform backward pass propagation of the derivative, and also either update the model (if to_update == this) or update another model or compute the model derivative (otherwise).
Note: in_value and out_value are the values of the input and output of the component, and these may be dummy variables if respectively BackpropNeedsInput() or BackpropNeedsOutput() return false for that component (not all components need these).
num_chunks lets us treat the input matrix as contiguous-in-time chunks of equal size; it only matters if splicing is involved.
Buffer for backpropagation: derivatives in the domain of 'patches_', 1row = vectorized rectangular feature patches, 1col = dim over speech frames,
Implements Component.
Definition at line 3966 of file nnet-component.cc.
References CuMatrixBase< Real >::AddCols(), Convolutional1dComponent::appended_conv_, CuMatrixBase< Real >::ColRange(), rnnlm::d, Convolutional1dComponent::filter_params_, Convolutional1dComponent::InputDim(), kaldi::kNoTrans, kaldi::kSetZero, CuMatrixBase< Real >::NumCols(), CuMatrixBase< Real >::NumRows(), Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, Convolutional1dComponent::patch_stride_, Convolutional1dComponent::RearrangeIndexes(), CuMatrix< Real >::Resize(), Convolutional1dComponent::ReverseIndexes(), and Convolutional1dComponent::Update().
|
inlinevirtual |
Reimplemented from Component.
Definition at line 1743 of file nnet-component.h.
|
inlinevirtual |
Reimplemented from Component.
Definition at line 1744 of file nnet-component.h.
References kaldi::cu::Copy(), kaldi::nnet3::DotProduct(), kaldi::nnet3::PerturbParams(), and Component::Propagate().
Definition at line 1767 of file nnet-component.h.
|
virtual |
Copy component (deep copy).
Implements Component.
Definition at line 4127 of file nnet-component.cc.
References Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, Convolutional1dComponent::Convolutional1dComponent(), Convolutional1dComponent::filter_params_, Convolutional1dComponent::is_gradient_, UpdatableComponent::learning_rate_, Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, and Convolutional1dComponent::patch_stride_.
|
virtual |
Here, "other" is a component of the same specific type.
This function computes the dot product in parameters, and is computed while automatically adjusting learning rates; typically, one of the two will actually contain the gradient.
Implements UpdatableComponent.
Definition at line 4120 of file nnet-component.cc.
References Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, kaldi::kTrans, kaldi::TraceMatMat(), and kaldi::VecVec().
|
virtual |
The following new virtual function returns the total dimension of the parameters in this class.
E.g. used for L-BFGS update
Reimplemented from UpdatableComponent.
Definition at line 4157 of file nnet-component.cc.
References Convolutional1dComponent::filter_params_.
|
virtual |
Reimplemented from UpdatableComponent.
Definition at line 3732 of file nnet-component.cc.
References Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, Convolutional1dComponent::InputDim(), kaldi::kTrans, UpdatableComponent::LearningRate(), Convolutional1dComponent::OutputDim(), Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, Convolutional1dComponent::patch_stride_, kaldi::TraceMatMat(), Convolutional1dComponent::Type(), and kaldi::VecVec().
void Init | ( | BaseFloat | learning_rate, |
int32 | input_dim, | ||
int32 | output_dim, | ||
int32 | patch_dim, | ||
int32 | patch_step, | ||
int32 | patch_stride, | ||
BaseFloat | param_stddev, | ||
BaseFloat | bias_stddev, | ||
bool | appended_conv | ||
) |
Definition at line 3669 of file nnet-component.cc.
References Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, UpdatableComponent::Init(), KALDI_ASSERT, Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, and Convolutional1dComponent::patch_stride_.
Referenced by MaxpoolingComponent::InitFromString(), Convolutional1dComponent::InitFromString(), and kaldi::nnet2::UnitTestConvolutional1dComponent().
void Init | ( | BaseFloat | learning_rate, |
int32 | patch_dim, | ||
int32 | patch_step, | ||
int32 | patch_stride, | ||
std::string | matrix_filename, | ||
bool | appended_conv | ||
) |
Definition at line 3697 of file nnet-component.cc.
References Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, UpdatableComponent::Init(), KALDI_ASSERT, CuMatrixBase< Real >::NumCols(), CuMatrixBase< Real >::NumRows(), Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, Convolutional1dComponent::patch_stride_, CuMatrixBase< Real >::Range(), and kaldi::ReadKaldiObject().
|
virtual |
Initialize, typically from a line of a config file.
The "args" will contain any parameters that need to be passed to the Component, e.g. dimensions.
Implements Component.
Definition at line 3761 of file nnet-component.cc.
References Convolutional1dComponent::Init(), Convolutional1dComponent::InputDim(), KALDI_ASSERT, KALDI_ERR, UpdatableComponent::learning_rate_, Convolutional1dComponent::OutputDim(), and kaldi::nnet2::ParseFromString().
Referenced by kaldi::nnet2::UnitTestConvolutional1dComponent().
|
virtual |
Get size of input vectors.
Implements Component.
Definition at line 3655 of file nnet-component.cc.
References Convolutional1dComponent::filter_params_, Convolutional1dComponent::patch_dim_, and Convolutional1dComponent::patch_stride_.
Referenced by Convolutional1dComponent::Backprop(), Convolutional1dComponent::Info(), Convolutional1dComponent::InitFromString(), Convolutional1dComponent::Propagate(), and Convolutional1dComponent::Update().
Definition at line 1768 of file nnet-component.h.
|
private |
|
virtual |
Get size of output vectors.
Implements Component.
Definition at line 3662 of file nnet-component.cc.
References Convolutional1dComponent::filter_params_, Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, and Convolutional1dComponent::patch_stride_.
Referenced by Convolutional1dComponent::Info(), and Convolutional1dComponent::InitFromString().
|
virtual |
We introduce a new virtual function that only applies to class UpdatableComponent.
This is used in testing.
Implements UpdatableComponent.
Definition at line 4140 of file nnet-component.cc.
References Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, CuVectorBase< Real >::SetRandn(), and CuMatrixBase< Real >::SetRandn().
|
virtual |
Perform forward pass propagation Input->Output.
Each row is one frame or training example. Interpreted as "num_chunks" equally sized chunks of frames; this only matters for layers that do things like context splicing. Typically this variable will either be 1 (when we're processing a single contiguous chunk of data) or will be the same as in.NumFrames(), but other values are possible if some layers do splicing.
Buffer of reshaped inputs: 1row = vectorized rectangular feature patches 1col = dim over speech frames,
Implements Component.
Definition at line 3819 of file nnet-component.cc.
References CuMatrixBase< Real >::AddVecToRows(), Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, ChunkInfo::CheckSize(), CuMatrixBase< Real >::ColRange(), CuMatrixBase< Real >::CopyCols(), rnnlm::d, Convolutional1dComponent::filter_params_, Convolutional1dComponent::InputDim(), KALDI_ASSERT, kaldi::kNoTrans, kaldi::kTrans, kaldi::kUndefined, ChunkInfo::NumChunks(), CuMatrixBase< Real >::NumCols(), CuMatrixBase< Real >::NumRows(), Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, and Convolutional1dComponent::patch_stride_.
|
virtual |
Implements Component.
Definition at line 4059 of file nnet-component.cc.
References Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, kaldi::nnet2::ExpectOneOrTwoTokens(), kaldi::ExpectToken(), Convolutional1dComponent::filter_params_, Convolutional1dComponent::is_gradient_, KALDI_ASSERT, UpdatableComponent::learning_rate_, Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, Convolutional1dComponent::patch_stride_, kaldi::ReadBasicType(), kaldi::ReadToken(), and Convolutional1dComponent::Type().
|
staticprivate |
Definition at line 3948 of file nnet-component.cc.
References rnnlm::i, and rnnlm::j.
Referenced by Convolutional1dComponent::Backprop().
Definition at line 3718 of file nnet-component.cc.
References Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, KALDI_ASSERT, Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, and Convolutional1dComponent::patch_stride_.
|
staticprivate |
Definition at line 3920 of file nnet-component.cc.
References rnnlm::i, rnnlm::j, and KALDI_ASSERT.
Referenced by Convolutional1dComponent::Backprop().
|
virtual |
This new virtual function scales the parameters by this amount.
Implements UpdatableComponent.
Definition at line 3894 of file nnet-component.cc.
References Convolutional1dComponent::bias_params_, and Convolutional1dComponent::filter_params_.
void SetParams | ( | const VectorBase< BaseFloat > & | bias, |
const MatrixBase< BaseFloat > & | filter | ||
) |
Definition at line 4150 of file nnet-component.cc.
References Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, and KALDI_ASSERT.
|
virtual |
Set parameters to zero, and if treat_as_gradient is true, we'll be treating this as a gradient so set the learning rate to 1 and make any other changes necessary (there's a variable we have to set for the MixtureProbComponent).
Implements UpdatableComponent.
Definition at line 4048 of file nnet-component.cc.
References Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, Convolutional1dComponent::is_gradient_, and UpdatableComponent::SetLearningRate().
|
inlinevirtual |
Implements Component.
Definition at line 1742 of file nnet-component.h.
Referenced by MaxpoolingComponent::Info(), Convolutional1dComponent::Info(), MaxpoolingComponent::InitFromString(), Convolutional1dComponent::Read(), and Convolutional1dComponent::Write().
void Update | ( | const CuMatrixBase< BaseFloat > & | in_value, |
const CuMatrixBase< BaseFloat > & | out_deriv | ||
) |
Buffer of reshaped inputs: 1row = vectorized rectangular feature patches 1col = dim over speech frames,
Definition at line 4162 of file nnet-component.cc.
References CuMatrixBase< Real >::AddMatBlocks(), CuVectorBase< Real >::AddRowSumMat(), Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, CuMatrixBase< Real >::ColRange(), CuMatrixBase< Real >::CopyCols(), rnnlm::d, Convolutional1dComponent::filter_params_, Convolutional1dComponent::InputDim(), kaldi::kNoTrans, kaldi::kSetZero, kaldi::kTrans, kaldi::kUndefined, UpdatableComponent::learning_rate_, CuMatrixBase< Real >::NumCols(), CuMatrixBase< Real >::NumRows(), Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, Convolutional1dComponent::patch_stride_, CuVector< Real >::Resize(), and CuMatrix< Real >::Resize().
Referenced by Convolutional1dComponent::Backprop().
|
virtual |
Write component to stream.
Implements Component.
Definition at line 4096 of file nnet-component.cc.
References Convolutional1dComponent::appended_conv_, Convolutional1dComponent::bias_params_, Convolutional1dComponent::filter_params_, Convolutional1dComponent::is_gradient_, UpdatableComponent::learning_rate_, Convolutional1dComponent::patch_dim_, Convolutional1dComponent::patch_step_, Convolutional1dComponent::patch_stride_, Convolutional1dComponent::Type(), kaldi::WriteBasicType(), and kaldi::WriteToken().
|
private |
Definition at line 1789 of file nnet-component.h.
Referenced by Convolutional1dComponent::Backprop(), Convolutional1dComponent::Convolutional1dComponent(), Convolutional1dComponent::Copy(), Convolutional1dComponent::Info(), Convolutional1dComponent::Init(), Convolutional1dComponent::Propagate(), Convolutional1dComponent::Read(), Convolutional1dComponent::Update(), and Convolutional1dComponent::Write().
Definition at line 1786 of file nnet-component.h.
Referenced by Convolutional1dComponent::Add(), Convolutional1dComponent::Copy(), Convolutional1dComponent::DotProduct(), Convolutional1dComponent::Info(), Convolutional1dComponent::Init(), Convolutional1dComponent::PerturbParams(), Convolutional1dComponent::Propagate(), Convolutional1dComponent::Read(), Convolutional1dComponent::Resize(), Convolutional1dComponent::Scale(), Convolutional1dComponent::SetParams(), Convolutional1dComponent::SetZero(), Convolutional1dComponent::Update(), and Convolutional1dComponent::Write().
Definition at line 1785 of file nnet-component.h.
Referenced by Convolutional1dComponent::Add(), Convolutional1dComponent::Backprop(), Convolutional1dComponent::Copy(), Convolutional1dComponent::DotProduct(), Convolutional1dComponent::GetParameterDim(), Convolutional1dComponent::Info(), Convolutional1dComponent::Init(), Convolutional1dComponent::InputDim(), Convolutional1dComponent::OutputDim(), Convolutional1dComponent::PerturbParams(), Convolutional1dComponent::Propagate(), Convolutional1dComponent::Read(), Convolutional1dComponent::Resize(), Convolutional1dComponent::Scale(), Convolutional1dComponent::SetParams(), Convolutional1dComponent::SetZero(), Convolutional1dComponent::Update(), and Convolutional1dComponent::Write().
|
private |
Definition at line 1790 of file nnet-component.h.
Referenced by Convolutional1dComponent::Convolutional1dComponent(), Convolutional1dComponent::Copy(), Convolutional1dComponent::Read(), Convolutional1dComponent::SetZero(), and Convolutional1dComponent::Write().
|
private |
Definition at line 1774 of file nnet-component.h.
Referenced by Convolutional1dComponent::Backprop(), Convolutional1dComponent::Copy(), Convolutional1dComponent::Info(), Convolutional1dComponent::Init(), Convolutional1dComponent::InputDim(), Convolutional1dComponent::OutputDim(), Convolutional1dComponent::Propagate(), Convolutional1dComponent::Read(), Convolutional1dComponent::Resize(), Convolutional1dComponent::Update(), and Convolutional1dComponent::Write().
|
private |
Definition at line 1775 of file nnet-component.h.
Referenced by Convolutional1dComponent::Backprop(), Convolutional1dComponent::Copy(), Convolutional1dComponent::Info(), Convolutional1dComponent::Init(), Convolutional1dComponent::OutputDim(), Convolutional1dComponent::Propagate(), Convolutional1dComponent::Read(), Convolutional1dComponent::Resize(), Convolutional1dComponent::Update(), and Convolutional1dComponent::Write().
|
private |
Definition at line 1776 of file nnet-component.h.
Referenced by Convolutional1dComponent::Backprop(), Convolutional1dComponent::Copy(), Convolutional1dComponent::Info(), Convolutional1dComponent::Init(), Convolutional1dComponent::InputDim(), Convolutional1dComponent::OutputDim(), Convolutional1dComponent::Propagate(), Convolutional1dComponent::Read(), Convolutional1dComponent::Resize(), Convolutional1dComponent::Update(), and Convolutional1dComponent::Write().