class_docstr: Three dimensional convolution.
class_docstr_tok: ["Three","dimensional","convolution","."]
docstr: Initializes the module.
  
  Args:
    output_channels: Number of output channels.
    kernel_shape: The shape of the kernel. Either an integer or a sequence of
      length 3.
    stride: Optional stride for the kernel. Either an integer or a sequence of
      length 3. Defaults to 1.
    rate: Optional kernel dilation rate. Either an integer or a sequence of
      length 3. 1 corresponds to standard ND convolution,
      `rate > 1` corresponds to dilated convolution. Defaults to 1.
    padding: Optional padding algorithm. Either ``VALID`` or ``SAME`` or
      a callable or sequence of callables of length 3. Any callables must
      take a single integer argument equal to the effective kernel size and
      return a list of two integers representing the padding before and after.
      See haiku.pad.* for more details and example functions.
      Defaults to ``SAME``. See:
      https://www.tensorflow.org/xla/operation_semantics#conv_convolution.
    with_bias: Whether to add a bias. By default, true.
    w_init: Optional weight initialization. By default, truncated normal.
    b_init: Optional bias initialization. By default, zeros.
    data_format: The data format of the input. Either ``NDHWC`` or ``NCDHW``.
      By default, ``NDHWC``.
    mask: Optional mask of the weights.
    feature_group_count: Optional number of groups in group convolution.
      Default value of 1 corresponds to normal dense convolution. If a higher
      value is used, convolutions are applied separately to that many groups,
      then stacked together. This reduces the number of parameters
      and possibly the compute for a given ``output_channels``. See:
      https://www.tensorflow.org/xla/operation_semantics#conv_convolution.
    name: The name of the module.
docstr_tok: ["Initializes","the","module",".","Args",":","output_channels",":","Number","of","output","channels",".","kernel_shape",":","The","shape","of","the","kernel",".","Either","an","integer","or","a","sequence","of","length","3.","stride",":","Optional","stride","for","the","kernel",".","Either","an","integer","or","a","sequence","of","length","3",".","Defaults","to","1.","rate",":","Optional","kernel","dilation","rate",".","Either","an","integer","or","a","sequence","of","length","3",".","1","corresponds","to","standard","ND","convolution",",","`","rate",">","1","`","corresponds","to","dilated","convolution",".","Defaults","to","1.","padding",":","Optional","padding","algorithm",".","Either","``","VALID","``","or","``","SAME","``","or","a","callable","or","sequence","of","callables","of","length","3",".","Any","callables","must","take","a","single","integer","argument","equal","to","the","effective","kernel","size","and","return","a","list","of","two","integers","representing","the","padding","before","and","after",".","See","haiku.pad",".","*","for","more","details","and","example","functions",".","Defaults","to","``","SAME","``",".","See",":","https",":","\/\/www.tensorflow.org\/xla\/operation_semantics","#","conv_convolution",".","with_bias",":","Whether","to","add","a","bias",".","By","default",",","true",".","w_init",":","Optional","weight","initialization",".","By","default",",","truncated","normal",".","b_init",":","Optional","bias","initialization",".","By","default",",","zeros",".","data_format",":","The","data","format","of","the","input",".","Either","``","NDHWC","``","or","``","NCDHW","``",".","By","default",",","``","NDHWC","``",".","mask",":","Optional","mask","of","the","weights",".","feature_group_count",":","Optional","number","of","groups","in","group","convolution",".","Default","value","of","1","corresponds","to","normal","dense","convolution",".","If","a","higher","value","is","used",",","convolutions","are","applied","separately","to","that","many","groups",",","then","stacked","together",".","This","reduces","the","number","of","parameters","and","possibly","the","compute","for","a","given","``","output_channels","``",".","See",":","https",":","\/\/www.tensorflow.org\/xla\/operation_semantics","#","conv_convolution",".","name",":","The","name","of","the","module","."]
code: def __init__(
      self,
      output_channels: int,
      kernel_shape: Union[int, Sequence[int]],
      stride: Union[int, Sequence[int]] = 1,
      rate: Union[int, Sequence[int]] = 1,
      padding: Union[
          str,
          Sequence[tuple[int, int]],
          hk.pad.PadFn,
          Sequence[hk.pad.PadFn],
      ] = "SAME",
      with_bias: bool = True,
      w_init: Optional[hk.initializers.Initializer] = None,
      b_init: Optional[hk.initializers.Initializer] = None,
      data_format: str = "NDHWC",
      mask: Optional[jax.Array] = None,
      feature_group_count: int = 1,
      name: Optional[str] = None,
  ):
      """Initializes the module.
  
      Args:
        output_channels: Number of output channels.
        kernel_shape: The shape of the kernel. Either an integer or a sequence of
          length 3.
        stride: Optional stride for the kernel. Either an integer or a sequence of
          length 3. Defaults to 1.
        rate: Optional kernel dilation rate. Either an integer or a sequence of
          length 3. 1 corresponds to standard ND convolution,
          `rate > 1` corresponds to dilated convolution. Defaults to 1.
        padding: Optional padding algorithm. Either ``VALID`` or ``SAME`` or
          a callable or sequence of callables of length 3. Any callables must
          take a single integer argument equal to the effective kernel size and
          return a list of two integers representing the padding before and after.
          See haiku.pad.* for more details and example functions.
          Defaults to ``SAME``. See:
          https://www.tensorflow.org/xla/operation_semantics#conv_convolution.
        with_bias: Whether to add a bias. By default, true.
        w_init: Optional weight initialization. By default, truncated normal.
        b_init: Optional bias initialization. By default, zeros.
        data_format: The data format of the input. Either ``NDHWC`` or ``NCDHW``.
          By default, ``NDHWC``.
        mask: Optional mask of the weights.
        feature_group_count: Optional number of groups in group convolution.
          Default value of 1 corresponds to normal dense convolution. If a higher
          value is used, convolutions are applied separately to that many groups,
          then stacked together. This reduces the number of parameters
          and possibly the compute for a given ``output_channels``. See:
          https://www.tensorflow.org/xla/operation_semantics#conv_convolution.
        name: The name of the module.
      """
      super().__init__(
          num_spatial_dims=3,
          output_channels=output_channels,
          kernel_shape=kernel_shape,
          stride=stride,
          rate=rate,
          padding=padding,
          with_bias=with_bias,
          w_init=w_init,
          b_init=b_init,
          data_format=data_format,
          mask=mask,
          feature_group_count=feature_group_count,
          name=name,
      )
  
imports: from collections.abc import Sequence
  from typing import Optional, Union
  from haiku._src import base
  from haiku._src import initializers
  from haiku._src import module
  from haiku._src import pad
  from haiku._src import utils
  import jax
  from jax import lax
  import jax.numpy
  import numpy
label_desc: Use image node_id 1 to create a new Conv3D object from inherited base classes: ConvND with example: obj = Conv3D(output_channels, kernel_shape, stride, rate, padding, with_bias, w_init, b_init, data_format, mask, feature_group_count, name)