code: def test_FFM_iterator(deeprec_resource_path):
      data_path = os.path.join(deeprec_resource_path, "xdeepfm")
      yaml_file = os.path.join(data_path, "xDeepFM.yaml")
      data_file = os.path.join(data_path, "sample_FFM_data.txt")
  
      if not os.path.exists(yaml_file):
          download_deeprec_resources(
              "https://recodatasets.z20.web.core.windows.net/deeprec/",
              data_path,
              "xdeepfmresources.zip",
          )
  
      hparams = prepare_hparams(yaml_file)
      iterator = FFMTextIterator(hparams, tf.Graph())
      assert iterator is not None
      for res in iterator.load_data_from_file(data_file):
          assert isinstance(res, tuple)
  
file_path: recommenders/tests/smoke/recommenders/recommender/test_deeprec_model.py
imports: import os
  import pytest
  from recommenders.datasets import movielens
  from recommenders.datasets.python_splitters import python_stratified_split
label_desc: Use image node_id 1 for calling a global function with example usage: test_FFM_iterator(deeprec_resource_path) without return types