code: def dot_sim(im, s):
      """
      Cosine similarity between all the image and sentence pairs
      """
      return im.mm(s.t())
  
file_path: towhee/towhee/models/mcprop/loss.py
imports: import torch
  from torch import nn
label_desc: Use image node_id 1 for calling a global function with example usage: dot_sim(im, s) and returns: im