MCPcopy Create free account
hub / github.com/AllentDan/LibtorchSegmentation / ASPPPoolingImpl

Method ASPPPoolingImpl

src/architectures/DeepLabDecoder.cpp:27–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

25}
26
27ASPPPoolingImpl::ASPPPoolingImpl(int in_channels, int out_channels) {
28 seq = torch::nn::Sequential(torch::nn::AdaptiveAvgPool2d(torch::nn::AdaptiveAvgPool2dOptions(1)),
29 torch::nn::Conv2d(conv_options(in_channels, out_channels, 1, 1, 0, 1, false)),
30 torch::nn::BatchNorm2d(torch::nn::BatchNorm2dOptions(out_channels)),
31 torch::nn::ReLU());
32 register_module("seq", seq);
33}
34
35torch::Tensor ASPPPoolingImpl::forward(torch::Tensor x) {
36 auto residual(x.clone());

Callers

nothing calls this directly

Calls 1

conv_optionsFunction · 0.85

Tested by

no test coverage detected