卷积#
卷积 Fprop#
卷积 fprop 计算
\( response = image * filter \)
C++ API#
std::shared_ptr<Tensor_attributes> conv_fprop(std::shared_ptr<Tensor_attributes> image,
std::shared_ptr<Tensor_attributes> filter,
Conv_fprop_attributes);
Conv_fprop_attributes 是一个带有 setters 的轻量级结构体
Conv_fprop_attributes&
set_padding(std::vector<int64_t>)
Conv_fprop_attributes&
set_stride(std::vector<int64_t>)
Conv_fprop_attributes&
set_dilation(std::vector<int64_t>)
Conv_fprop_attributes&
set_name(std::string const&)
Conv_fprop_attributes&
set_compute_data_type(DataType_t value)
Conv_fprop_attributes&
set_convolution_mode(ConvolutionMode_t mode_)
Python API#
conv_fprop
image
weight
padding
stride
dilation
compute_data_type
name
卷积 Dgrad#
卷积 dgrad 计算反向传播期间的数据梯度。
C++ API#
std::shared_ptr<Tensor_attributes> conv_dgrad(std::shared_ptr<Tensor_attributes> image,
std::shared_ptr<Tensor_attributes> filter,
Conv_dgrad_attributes);
Conv_dgrad_attributes 是一个带有 setters 的轻量级结构体
Conv_dgrad_attributes&
set_padding(std::vector<int64_t>)
Conv_dgrad_attributes&
set_stride(std::vector<int64_t>)
Conv_dgrad_attributes&
set_dilation(std::vector<int64_t>)
Conv_dgrad_attributes&
set_name(std::string const&)
Conv_dgrad_attributes&
set_compute_data_type(DataType_t value)
Conv_dgrad_attributes&
set_convolution_mode(ConvolutionMode_t mode_)
Python API#
conv_dgrad
filter
loss
padding
stride
dilation
compute_data_type
name
卷积 Wgrad#
卷积 wgrad 计算反向传播期间的权重梯度。
C++ API#
std::shared_ptr<Tensor_attributes> conv_wgrad(std::shared_ptr<Tensor_attributes> image,
std::shared_ptr<Tensor_attributes> filter,
Conv_wgrad_attributes);
Conv_wgrad_attributes 是一个带有 setters 的轻量级结构体
Conv_wgrad_attributes&
set_padding(std::vector<int64_t>)
Conv_wgrad_attributes&
set_stride(std::vector<int64_t>)
Conv_wgrad_attributes&
set_dilation(std::vector<int64_t>)
Conv_wgrad_attributes&
set_name(std::string const&)
Conv_wgrad_attributes&
set_compute_data_type(DataType_t value)
Conv_wgrad_attributes&
set_convolution_mode(ConvolutionMode_t mode_)
Python API#
conv_wgrad
image
loss
padding
stride
dilation
compute_data_type
name