decoderblock and center block
| 24 | |
| 25 | //decoderblock and center block |
| 26 | class DecoderBlockImpl: public torch::nn::Module{ |
| 27 | public: |
| 28 | DecoderBlockImpl(int in_channels, int skip_channels, int out_channels, bool skip = true, bool attention = false); |
| 29 | torch::Tensor forward(torch::Tensor x, torch::Tensor skip); |
| 30 | private: |
| 31 | Conv2dReLU conv1{nullptr}; |
| 32 | Conv2dReLU conv2{nullptr}; |
| 33 | SCSEModule attention1{nullptr}; |
| 34 | SCSEModule attention2{nullptr}; |
| 35 | torch::nn::Upsample upsample{nullptr}; |
| 36 | bool is_skip = true; |
| 37 | };TORCH_MODULE(DecoderBlock); |
| 38 | |
| 39 | torch::nn::Sequential CenterBlock(int in_channels, int out_channels); |
| 40 |
nothing calls this directly
no outgoing calls
no test coverage detected