class_docstr: Class for computing the relevance propagation and supplying
  the necessary forward hooks for all layers.
class_docstr_tok: ["Class","for","computing","the","relevance","propagation","and","supplying","the","necessary","forward","hooks","for","all","layers","."]
docstr: Get dimension-specific convolution.
  The forward pass and inversion are made in a
  'dimensionality-agnostic' manner and are the same for
  all nd instances of the layer, except for the functional
  that needs to be used.
  
  Args:
      conv_module: instance of convolutional layer.
  
  Returns:
      The correct functional used in the convolutional layer.
docstr_tok: ["Get","dimension-specific","convolution",".","The","forward","pass","and","inversion","are","made","in","a","'dimensionality-agnostic","'","manner","and","are","the","same","for","all","nd","instances","of","the","layer",",","except","for","the","functional","that","needs","to","be","used",".","Args",":","conv_module",":","instance","of","convolutional","layer",".","Returns",":","The","correct","functional","used","in","the","convolutional","layer","."]
code: def get_conv_method(conv_module):
      """
      Get dimension-specific convolution.
      The forward pass and inversion are made in a
      'dimensionality-agnostic' manner and are the same for
      all nd instances of the layer, except for the functional
      that needs to be used.
  
      Args:
          conv_module: instance of convolutional layer.
  
      Returns:
          The correct functional used in the convolutional layer.
  
      """
  
      conv_func_mapper = {
          torch.nn.Conv1d: F.conv1d,
          torch.nn.Conv2d: F.conv2d,
          torch.nn.Conv3d: F.conv3d,
      }
      return conv_func_mapper[type(conv_module)]
  
imports: import torch
  import torch.nn
  import numpy
  import torch.nn.functional
label_desc: Use image node_id 5 for calling the RelevancePropagator obj's underlying member method code with example usage: obj.get_conv_method(conv_module) and returns: conv_func_mapper