code: def test_clean_data():
      X = {
          "train": np.array(
              [
                  ["a", "b", "c"],
                  ["d", "e", "f"],
                  ["g", "h", "i"],
                  ["j", "k", "l"],
              ]
          ),
          "valid": np.array(
              [
                  ["a", "b", "c"],
                  ["x", "e", "f"],
                  ["g", "a", "i"],
                  ["j", "k", "y"],
              ]
          ),
          "test": np.array(
              [
                  ["a", "b", "c"],
                  ["d", "e", "x"],
                  ["g", "b", "i"],
                  ["y", "k", "l"],
              ]
          ),
      }
  
      clean_X, valid_idx, test_idx = _clean_data(X, return_idx=True)
  
      np.testing.assert_array_equal(clean_X["train"], X["train"])
      np.testing.assert_array_equal(
          clean_X["valid"], np.array([["a", "b", "c"]])
      )
      np.testing.assert_array_equal(
          clean_X["test"], np.array([["a", "b", "c"], ["g", "b", "i"]])
      )
      np.testing.assert_array_equal(
          valid_idx, np.array([True, False, False, False])
      )
      np.testing.assert_array_equal(
          test_idx, np.array([True, False, True, False])
      )
  
file_path: AmpliGraph/tests/ampligraph/datasets/test_datasets.py
imports: from ampligraph.datasets import load_wn18, load_fb15k, load_fb15k_237, load_yago3_10, load_wn18rr, load_wn11, load_fb13
  from ampligraph.datasets.datasets import _clean_data
  import os
  import numpy
  import pytest
label_desc: Use image node_id 1 for calling a global function with example usage: test_clean_data() without return types