class_docstr: HR2O_NL module for ACAR head.
  
  Args:
      - hidden_dim (`int`):
          Hidden dimension.
      - kernel_size (`int`):
          Kernel size.
      - mlp_1x1 (`bool`):
          Whether to use 1 as kernel size.
class_docstr_tok: ["HR2O_NL","module","for","ACAR","head",".","Args",":","-","hidden_dim","(","`","int","`",")",":","Hidden","dimension",".","-","kernel_size","(","`","int","`",")",":","Kernel","size",".","-","mlp_1x1","(","`","bool","`",")",":","Whether","to","use","1","as","kernel","size","."]
code: def forward(self, x):
      query = self.conv_q(x).unsqueeze(1)
      key = self.conv_k(x).unsqueeze(0)
      att = (query * key).sum(2) / (self.hidden_dim**0.5)
      att = nn.Softmax(dim=1)(att)
      value = self.conv_v(x)
      virt_feats = (att.unsqueeze(2) * value).sum(1)
  
      virt_feats = self.norm(virt_feats)
      virt_feats = nn.functional.relu(virt_feats)
      virt_feats = self.conv(virt_feats)
      virt_feats = self.dp(virt_feats)
  
      x = x + virt_feats
      return x
  
file_path: towhee/towhee/models/acar_net/head.py
imports: import math
  import torch
  from torch import nn
  import torchvision
label_desc: Use image node_id 2 for calling the HR2ONL obj's underlying member method code with example usage: obj.forward(x) and returns: x