code: def conv_general_dilated(
      x: torch.Tensor,
      filters: torch.Tensor,
      strides: Union[
          int, Tuple[int], Tuple[int, int], Tuple[int, int, int]
      ],
      padding: Union[str, int, Sequence[Tuple[int, int]]],
      /,
      *,
      dims: int = 2,
      data_format: str = "channel_last",
      filter_format: str = "channel_last",
      feature_group_count: int = 1,
      x_dilations: Union[
          int, Tuple[int], Tuple[int, int], Tuple[int, int, int]
      ] = 1,
      dilations: Union[
          int, Tuple[int], Tuple[int, int], Tuple[int, int, int]
      ] = 1,
      bias: Optional[torch.Tensor] = None,
      out: Optional[torch.Tensor] = None,
  ):
      # permuting dims based on formats
      if data_format == "channel_last":
          x = x.permute(0, dims + 1, *range(1, dims + 1))
      if filter_format == "channel_last":
          filters = filters.permute(-1, -2, *range(dims))
  
      x = _x_dil_before_conv(x, dims, x_dilations)
      x, padding = _pad_before_conv(
          x, filters, strides, padding, dims, dilations, "channel_first"
      )
  
      if dims == 1:
          res = torch.nn.functional.conv1d(
              x,
              filters,
              bias,
              strides,
              padding,
              dilations,
              feature_group_count,
          )
      elif dims == 2:
          res = torch.nn.functional.conv2d(
              x,
              filters,
              bias,
              strides,
              padding,
              dilations,
              feature_group_count,
          )
      else:
          res = torch.nn.functional.conv3d(
              x,
              filters,
              bias,
              strides,
              padding,
              dilations,
              feature_group_count,
          )
  
      if data_format == "channel_last":
          return res.permute(0, *range(2, dims + 2), 1)
      return res
  
imports: from typing import Optional, Tuple, Union, Sequence
  import torch
  import ivy
  from ivy.func_wrapper import with_unsupported_dtypes, with_supported_dtypes
  from .None import backend_version
  from ivy.functional.ivy.layers import _get_embed_dim, _handle_padding, _deconv_length
label_desc: Use image node_id 17 for calling a global function with example usage: conv_general_dilated() and returns: res, res