Skip to content

[Feature Request] Groups added to Conv2dΒ #100

Open
@Aavache

Description

@Aavache

πŸš€ What is the purpose of this issue?

According to the documentation, these are the parameters available for Conv2d.

  • in_channels (int) – The number of input channels.
  • out_channels (int) – The number of output channels.
  • kernel_size (int or tuple) – The size of the convolution filters.
  • stride (int or tuple, optional) – The size of the stride when applying the filter. Default: 0.
  • padding (int or tuple, optional) – How many positions to 0-pad the input with. Default: 0.
  • bias (bool, optional) – If True add a learnable bias to the output. Default: True

However, the dilation and groups parameter as defined in the torch implementation of Conv2d, would be desirable to implement well-known architectures, e.g. ASPP. The following is the description of these two parameters according to torch:

  • dilation controls the spacing between the kernel points; also known as the Γ  trous algorithm. It is harder to describe, but this link has a nice visualization of what dilation does.

  • groups control the connections between inputs and outputs. in_channels and out_channels must both be divisible by groups. For example, at groups=1, all inputs are convolved to all outputs. At groups=2, the operation becomes equivalent to having two conv layers side by side, each seeing half the input channels and producing half the output channels, and both subsequently concatenated.

Thank you for your attention πŸ‘

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions