code: def test_pytorch_cos_sim() -> None:
      """Tests the correct computation of util.pytorch_cos_scores"""
      a = np.random.randn(50, 100)
      b = np.random.randn(50, 100)
  
      sklearn_pairwise = sklearn.metrics.pairwise.cosine_similarity(
          a, b
      )
      pytorch_cos_scores = util.pytorch_cos_sim(a, b).numpy()
      for i in range(len(sklearn_pairwise)):
          for j in range(len(sklearn_pairwise[i])):
              assert (
                  abs(sklearn_pairwise[i][j] - pytorch_cos_scores[i][j])
                  < 0.001
              )
  
file_path: sentence-transformers/tests/test_util.py
imports: import numpy
  import sklearn
  import torch
  from sentence_transformers import SentenceTransformer, util
label_desc: Use image node_id 2 for calling a global function with example usage: test_pytorch_cos_sim() without return types