class_docstr: Unit tests for OIVF. Some of these unit tests first copy the required test data objects and puts them in the tempdir created by the context manager.
class_docstr_tok: ["Unit","tests","for","OIVF",".","Some","of","these","unit","tests","first","copy","the","required","test","data","objects","and","puts","them","in","the","tempdir","created","by","the","context","manager","."]
docstr: Test evaluate step using test data objects, no margin evaluation, single index.
docstr_tok: ["Test","evaluate","step","using","test","data","objects",",","no","margin","evaluation",",","single","index","."]
code: def test_evaluate_without_margin_OPQ(self) -> None:
      """
      Test evaluate step using test data objects, no margin evaluation, single index.
      """
      with tempfile.TemporaryDirectory() as tmpdirname:
          data_creator = TestDataCreator(
              tempdir=tmpdirname,
              dimension=8,
              data_type=np.float32,
              index_factory=["OPQ4,IVF256,PQ4"],
              training_sample=9984,
              num_files=3,
              file_size=10000,
              nprobe=200,
              k=2,
              metric="METRIC_L2",
              index_shard_size=10000,
              query_batch_size=10000,
              evaluation_sample=100,
              with_queries_ds=True,
          )
          data_creator.create_test_data()
          test_args = data_creator.setup_cli("train_index")
          process_options_and_run_jobs(test_args)
          test_args = data_creator.setup_cli("index_shard")
          process_options_and_run_jobs(test_args)
          test_args = data_creator.setup_cli("merge_index")
          process_options_and_run_jobs(test_args)
          test_args = data_creator.setup_cli("evaluate")
          process_options_and_run_jobs(test_args)
          common_path = (
              tmpdirname + "/my_queries_data_in_my_test_data/eval/"
          )
          for filename in A_INDEX_OPQ_FILES:
              file_to_check = common_path + filename
              self.assert_file_exists(file_to_check)
  
file_path: faiss/demos/offline_ivf/tests/test_offline_ivf.py
imports: import numpy
  import unittest
  from utils import load_config
  import pathlib
  import tempfile
  from typing import List
  from tests.testing_utils import TestDataCreator
  from run import process_options_and_run_jobs
label_desc: Use image node_id 8 for calling the TestOIVF obj's underlying member method code with example usage: obj.test_evaluate_without_margin_OPQ() without return types