code: def test_get_object_corruption_scores():
      model = HolE(k=3)
  
      ent_matrix = np.array(
          [[4, 4, 4, 6, 6, 6], [9, 9, 9, 19, 19, 19]]
      ).astype(np.float32)
      triples = [
          np.array(
              [[1, 1, 1, 2, 2, 2], [10, 10, 10, 11, 11, 11]]
          ).astype(np.float32),
          np.array(
              [[5, 5, 5, 3, 3, 3], [100, 100, 100, 101, 101, 101]]
          ).astype(np.float32),
          np.array([[4, 4, 4, 6, 6, 6], [9, 9, 9, 19, 19, 19]]).astype(
              np.float32
          ),
      ]
      scores = np.around(
          model._get_object_corruption_scores(
              triples, ent_matrix
          ).numpy(),
          2,
      )
      assert (
          np.diag(scores)
          == 2 * np.array([222.0, 117273.0], dtype=np.float32) / 3.0
      ).all(), "ComplEx: Scores don't match!"
  
imports: from ampligraph.latent_features.layers.scoring import HolE
  import pytest
  import tensorflow
  import numpy
label_desc: Use image node_id 3 for calling a global function with example usage: test_get_object_corruption_scores() without return types