class_docstr: A convolutional layer that can be used with LoRA.
code: def forward(
      self, hidden_states: torch.Tensor, scale: float = 1.0
  ) -> torch.Tensor:
      if self.lora_layer is None:
          # make sure to the functional Conv2D function as otherwise torch.compile's graph will break
          # see: https://github.com/huggingface/diffusers/pull/4315
          return F.conv2d(
              hidden_states,
              self.weight,
              self.bias,
              self.stride,
              self.padding,
              self.dilation,
              self.groups,
          )
      else:
          original_outputs = F.conv2d(
              hidden_states,
              self.weight,
              self.bias,
              self.stride,
              self.padding,
              self.dilation,
              self.groups,
          )
          return original_outputs + (
              scale * self.lora_layer(hidden_states)
          )
  
imports: from typing import Optional, Tuple, Union
  import torch
  import torch.nn.functional
  from torch import nn
  from ..utils import logging
  from ..utils.import_utils import is_transformers_available
label_desc: Use image node_id 5 for calling the LoRACompatibleConv obj's underlying member method code with example usage: obj.forward(hidden_states, scale) and returns: F, unknown