code: def test_count_refs(self):
      quantizer = faiss.IndexFlatL2(d)
      index = faiss.IndexIVFFlat(quantizer, d, 10)
      refc1 = sys.getrefcount(quantizer)
      del index
      gc.collect()
      refc2 = sys.getrefcount(quantizer)
      assert refc2 == refc1 - 1
  
file_path: faiss/tests/test_referenced_objects.py
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import numpy
  import unittest
  import faiss
  import sys
  import gc
label_desc: Use image node_id 2 for calling the TestReferenced obj's underlying member method code with example usage: obj.test_count_refs() without return types