A library for efficient similarity search and clustering of dense vectors.
This report summarizes scanner evidence for facebookresearch/faiss, a C++ project with 41,124 GitHub stars. SynthScan examined 272,533 lines of code across 961 source files, recording 1069 pattern matches distributed across 19 syntactic categories. The legacy adjusted pattern signal is 4.8 (Low pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 887 finding(s).
Are imports declared and package/API names verified? 105 finding(s).
Are wrappers, guards, and repeated structures necessary? 524 finding(s).
Which changes need focused human review? 1069 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 1069 distinct pattern matches across 19 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_local_search_quantizer.py | 187 | def test_update_codebooks_with_double(self): | CODE |
| LOW | tests/test_local_search_quantizer.py | 210 | def test_compute_binary_terms(self): | CODE |
| LOW | tests/test_local_search_quantizer.py | 472 | def test_index_accuracy_reconstruct(self): | CODE |
| LOW | tests/test_local_search_quantizer.py | 478 | def test_index_accuracy_cqint(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 244 | def test_by_residual_no_precomputed(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 295 | def test_qloss_no_residual_ip(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 298 | def test_qloss_by_residual_ip(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 354 | def test_equiv_pq_encode_decode(self): | CODE |
| LOW⚡ | tests/test_fast_scan_ivf.py | 440 | def test_no_residual_single_query(self): | CODE |
| LOW⚡ | tests/test_fast_scan_ivf.py | 443 | def test_by_residual_single_query(self): | CODE |
| LOW⚡ | tests/test_fast_scan_ivf.py | 446 | def test_no_residual_ip_single_query(self): | CODE |
| LOW⚡ | tests/test_fast_scan_ivf.py | 449 | def test_by_residual_ip_single_query(self): | CODE |
| LOW⚡ | tests/test_fast_scan_ivf.py | 452 | def test_no_residual_odd_dim_single_query(self): | CODE |
| LOW⚡ | tests/test_fast_scan_ivf.py | 455 | def test_by_residual_odd_dim_single_query(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 1096 | def test_fastscan_defaults_roundtrip(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 1109 | def test_fastscan_max_lists_num_caps_probes(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 1128 | def test_fastscan_ensure_topk_full_fills_heap(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 1146 | def test_fastscan_ensure_topk_full_with_restrictive_selector(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 1167 | def test_fastscan_ensure_topk_full_multi_query_works(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 1192 | def test_fastscan_range_honors_max_empty_result_buckets(self): | CODE |
| LOW | tests/test_fast_scan_ivf.py | 1228 | def test_fastscan_fields_exposed(self): | CODE |
| LOW | tests/test_contrib.py | 197 | def test_query_iterator_similarity_metric(self): | CODE |
| LOW | tests/test_contrib.py | 360 | def test_equal_time_better_perf_shadows(self): | CODE |
| LOW | tests/test_contrib.py | 378 | def test_index_pretransformed(self): | CODE |
| LOW | tests/test_contrib.py | 529 | def test_range_search_preassigned_coarse_dis_none_matches_zeros(self): | CODE |
| LOW | tests/test_contrib.py | 906 | def test_ondisk_merge_with_shift_ids(self): | CODE |
| LOW | tests/test_contrib.py | 924 | def test_ivf_scalar_quantizer_types(self): | CODE |
| LOW | tests/test_contrib.py | 957 | def test_scalar_quantizer_types(self): | CODE |
| LOW | tests/test_contrib.py | 985 | def test_get_code_size_hnsw_non_default_m(self): | CODE |
| LOW | tests/test_contrib.py | 1003 | def test_get_code_size_ivf_hnsw_non_default_m(self): | CODE |
| LOW | tests/test_contrib.py | 1015 | def test_get_code_size_hnsw_roundtrip(self): | CODE |
| LOW | tests/test_contrib.py | 1024 | def test_hnsw_storage_reverse_index_factory(self): | CODE |
| LOW | tests/test_contrib.py | 1041 | def test_get_code_size_hnsw_non_flat_storage(self): | CODE |
| LOW | tests/test_contrib.py | 1065 | def test_ivfpqr_reverse_index_factory(self): | CODE |
| LOW | tests/test_contrib.py | 1074 | def test_rabitq_reverse_index_factory(self): | CODE |
| LOW | tests/test_graph_based.py | 113 | def test_hnsw_unbounded_queue(self): | CODE |
| LOW | tests/test_graph_based.py | 393 | def test_add_nan_vector_to_ivf_hnsw(self): | CODE |
| LOW | tests/test_graph_based.py | 611 | def test_nsg_supports_pre_built_knn_graph(self): | CODE |
| LOW | tests/test_graph_based.py | 620 | def test_nsg_with_pre_built_knn_graph_throws_when_rebuilding_via_add(self): | CODE |
| LOW | tests/test_graph_based.py | 639 | def test_nsg_rebuild_throws_with_pre_built_knn_graph(self): | CODE |
| LOW | tests/test_fast_scan.py | 215 | def do_test_recall_matches_pq(self, d): | CODE |
| LOW | tests/test_clustering_initialization.py | 23 | def verify_centroids_from_dataset(test_case, centroids, dataset): | CODE |
| LOW | tests/test_clustering_initialization.py | 63 | def test_initialization_methods(self): | CODE |
| LOW | tests/test_clustering_initialization.py | 128 | def test_with_existing_centroids(self): | CODE |
| LOW | tests/test_super_kmeans.py | 14 | def test_train_rejects_too_few_points(self): | CODE |
| LOW | tests/test_super_kmeans.py | 48 | def test_objective_decreases_monotonically(self): | CODE |
| LOW | tests/test_super_kmeans.py | 63 | def test_pruned_iter_assignments_close_to_vanilla(self): | CODE |
| LOW | tests/test_super_kmeans.py | 84 | def test_spherical_objective_close_to_vanilla_spherical(self): | CODE |
| LOW | tests/test_super_kmeans.py | 110 | def test_spherical_produces_unit_centroids(self): | CODE |
| LOW | tests/test_super_kmeans.py | 125 | def test_use_super_kmeans_field_is_inherited(self): | CODE |
| LOW | tests/test_super_kmeans.py | 133 | def test_pruning_rate_in_expected_range(self): | CODE |
| LOW | tests/test_super_kmeans.py | 154 | def test_pdx_offset_correct_for_unaligned_y_batch(self): | CODE |
| LOW | tests/test_super_kmeans.py | 209 | def test_cluster_splitting_with_many_duplicates(self): | CODE |
| LOW | tests/test_super_kmeans.py | 236 | def test_train_populates_kmeans_surface(self): | CODE |
| LOW | tests/test_super_kmeans.py | 254 | def test_final_obj_matches_vanilla_kmeans(self): | CODE |
| LOW⚡ | tests/test_svs_py.py | 507 | def test_svs_range_search_selected(self): | CODE |
| LOW⚡ | tests/test_svs_py.py | 511 | def test_svs_add_search_remove_interface(self): | CODE |
| LOW⚡ | tests/test_svs_py.py | 515 | def test_svs_batch_operations(self): | CODE |
| LOW⚡ | tests/test_svs_py.py | 878 | def test_svs_leanvec_ood_training(self): | CODE |
| LOW⚡ | tests/test_svs_py.py | 883 | def test_svs_leanvec_ood_training_smaller(self): | CODE |
| 381 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | CMakeLists.txt | 1 | # @lint-ignore-every LICENSELINT | COMMENT |
| LOW | pyproject-gpu-cuvs.toml | 141 | # auditwheel excludes (not vendored; supplied at runtime by nvidia-* / libcuvs-cu13 | COMMENT |
| LOW | tutorial/python/11-SVS.py | 1 | # Portions Copyright (c) Meta Platforms, Inc. and affiliates. | COMMENT |
| LOW | tests/test_fastscan_filter.cpp | 1 | /* | COMMENT |
| LOW | tests/test_svs.cpp | 21 | * limitations under the License. | COMMENT |
| LOW | tests/test_hnsw.cpp | 1 | /* | COMMENT |
| LOW | tests/test_transfer_invlists.cpp | 1 | /* | COMMENT |
| LOW | tests/test_svs_py.py | 1 | # Portions Copyright (c) Meta Platforms, Inc. and affiliates. | COMMENT |
| LOW | tests/test_zerocopy.cpp | 1 | /* | COMMENT |
| LOW | tests/test_sq_rvv_tail_and_semantics.cpp | 61 | #include <memory> | COMMENT |
| LOW | tests/test_sq_rvv_tail_and_semantics.cpp | 481 | // =========================================================================== | COMMENT |
| LOW | tests/test_ivf_index.cpp | 1 | /* | COMMENT |
| LOW | tests/test_ivf_index.cpp | 21 | #include <faiss/IndexIVFFlat.h> | COMMENT |
| LOW | tests/test_meta_index.py | 141 | if with_threads: | COMMENT |
| LOW | tests/test_distances_dispatch.cpp | 1 | /* | COMMENT |
| LOW | tests/test_distances_dispatch.cpp | 21 | // * Functions returning an integer (fvec_L2sqr_ny_nearest's chosen | COMMENT |
| LOW | tests/test_ivf_early_termination.cpp | 1 | /* | COMMENT |
| LOW | tests/test_ivf_sharding.cpp | 1 | /* | COMMENT |
| LOW | tests/test_super_kmeans_foundations.cpp | 1 | /* | COMMENT |
| LOW | tests/test_super_kmeans_foundations.cpp | 21 | #include <faiss/utils/fp16.h> | COMMENT |
| LOW | tests/test_pipnn.cpp | 1 | /* | COMMENT |
| LOW | tests/test_pipnn.cpp | 21 | #include <tuple> | COMMENT |
| LOW | tests/test_omp_exception_safety.cpp | 1 | /* | COMMENT |
| LOW | tests/test_omp_exception_safety.cpp | 381 | std::vector<idx_t> labels(1); | COMMENT |
| LOW | tests/bench_hnsw_deterministic.py | 1 | # Copyright (c) Meta Platforms, Inc. and affiliates. | COMMENT |
| LOW | tests/test_mmap.cpp | 1 | /* | COMMENT |
| LOW | tests/test_scalar_quantizer.cpp | 1 | /* | COMMENT |
| LOW | tests/test_single_query_collect_handler.cpp | 21 | * and calling pq4_accumulate_loop_qbs_fixed_scaler_simd directly. | COMMENT |
| LOW | tests/test_custom_result_handler.cpp | 1 | /* | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 1 | /* | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 21 | #include <faiss/IndexAdditiveQuantizer.h> | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 161 | // Reading a non-canonical byte directly into a bool is UB and trips | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 181 | expect_read_throws_with(buf, "invalid bool encoding"); | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 821 | std::vector<uint8_t> buf; | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 1461 | // entry_point | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 3301 | // ----------------------------------------------------------------------- | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 3701 | push_index_header(buf, /*d=*/4, /*ntotal=*/0); | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 3921 | } | COMMENT |
| LOW | tests/test_read_index_deserialize.cpp | 4401 | // name, and the entry size straight off the stream. All three are | COMMENT |
| LOW | .github/actions/build_cmake/action.yml | 61 | # bin/python is 3.14, and forcing it strands conda's own compiled | COMMENT |
| LOW | .github/actions/build_cmake/action.yml | 101 | conda install -y -q -p "$CONDA" mkl=2024.2.2 mkl-devel=2024.2.2 | COMMENT |
| LOW | .github/actions/build_cmake/action.yml | 141 | if [ "${{ inputs.rocm }}" = "ON" ]; then | COMMENT |
| LOW | .github/actions/build_cmake/action.yml | 341 | COMMENT | |
| LOW | faiss/index_factory.cpp | 21 | #include <faiss/Index2Layer.h> | COMMENT |
| LOW | faiss/index_factory.cpp | 41 | #include <faiss/IndexLattice.h> | COMMENT |
| LOW | faiss/index_factory.cpp | 61 | #include <faiss/svs/IndexSVSIVF.h> | COMMENT |
| LOW | faiss/IndexFastScan.cpp | 1 | /* | COMMENT |
| LOW | faiss/factory_tools.cpp | 21 | #include <faiss/IndexIVFFlat.h> | COMMENT |
| LOW | faiss/CMakeLists.txt | 1 | # Portions Copyright (c) Meta Platforms, Inc. and affiliates. | COMMENT |
| LOW | faiss/IndexIVFSQFastScan.cpp | 21 | #include <faiss/impl/ScalarQuantizer.h> | COMMENT |
| LOW | faiss/IndexHNSW.cpp | 21 | COMMENT | |
| LOW | faiss/IndexHNSW.cpp | 61 | // (e.g. METRIC_INNER_PRODUCT), distance values are real similarity scores | COMMENT |
| LOW | faiss/IndexIVF.cpp | 1 | /* | COMMENT |
| LOW | faiss/IndexFlat.cpp | 1 | /* | COMMENT |
| LOW | faiss/IndexFlat.cpp | 861 | FAISS_THROW_IF_NOT(batch_size == 1); | COMMENT |
| LOW | faiss/AutoTune.cpp | 21 | #include <faiss/utils/utils.h> | COMMENT |
| LOW | faiss/IndexIVF.h | 101 | /// 0 means unlimited, i.e. bounded only by nprobe. When set together | COMMENT |
| LOW | faiss/IndexIVFPQ.cpp | 21 | #include <faiss/utils/distances_dispatch.h> | COMMENT |
| LOW | faiss/index_io.h | 121 | // When nonzero, deserialization rejects loop-driving fields (nlist, | COMMENT |
| LOW | faiss/index_io.h | 141 | // When nonzero, deserialization rejects IndexLattice payloads whose | COMMENT |
| 216 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_referenced_objects.py | 7 | CODE | |
| LOW | tests/test_referenced_objects.py | 7 | CODE | |
| LOW | tests/test_referenced_objects.py | 7 | CODE | |
| LOW | tests/test_referenced_objects.py | 7 | CODE | |
| LOW | tests/test_product_quantizer.py | 6 | CODE | |
| LOW | tests/test_product_quantizer.py | 6 | CODE | |
| LOW | tests/test_product_quantizer.py | 6 | CODE | |
| LOW | tests/test_index_binary_from_float.py | 6 | CODE | |
| LOW | tests/test_index_binary_from_float.py | 6 | CODE | |
| LOW | tests/test_index_binary_from_float.py | 6 | CODE | |
| LOW | tests/test_binary_io.py | 8 | CODE | |
| LOW | tests/test_binary_io.py | 8 | CODE | |
| LOW | tests/test_binary_io.py | 8 | CODE | |
| LOW | tests/test_binary_io.py | 8 | CODE | |
| LOW | tests/test_scalar_quantizer_correctness.py | 6 | CODE | |
| LOW | tests/test_scalar_quantizer_correctness.py | 6 | CODE | |
| LOW | tests/test_scalar_quantizer_correctness.py | 6 | CODE | |
| LOW | tests/test_sq_fastscan.py | 7 | CODE | |
| LOW | tests/test_sq_fastscan.py | 7 | CODE | |
| LOW | tests/test_sq_fastscan.py | 7 | CODE | |
| LOW | tests/test_wheel_smoke.py | 174 | CODE | |
| LOW | tests/bench_transposed_encode.py | 6 | CODE | |
| LOW | tests/test_build_blocks.py | 6 | CODE | |
| LOW | tests/test_build_blocks.py | 6 | CODE | |
| LOW | tests/test_build_blocks.py | 6 | CODE | |
| LOW | tests/bench_hnsw_deterministic.py | 29 | CODE | |
| LOW | tests/test_binary_factory.py | 6 | CODE | |
| LOW | tests/test_binary_factory.py | 6 | CODE | |
| LOW | tests/test_binary_factory.py | 6 | CODE | |
| LOW | tests/test_index.py | 7 | CODE | |
| LOW | tests/test_index.py | 7 | CODE | |
| LOW | tests/test_index.py | 7 | CODE | |
| LOW | tests/test_omp_threads_py.py | 6 | CODE | |
| LOW | tests/test_omp_threads_py.py | 6 | CODE | |
| LOW | tests/test_omp_threads_py.py | 6 | CODE | |
| LOW | tests/test_omp_threads_py.py | 6 | CODE | |
| LOW | tests/test_index_accuracy.py | 6 | CODE | |
| LOW | tests/test_index_accuracy.py | 6 | CODE | |
| LOW | tests/test_index_accuracy.py | 6 | CODE | |
| LOW | tests/test_ivflib.py | 6 | CODE | |
| LOW | tests/test_ivflib.py | 6 | CODE | |
| LOW | tests/test_ivflib.py | 6 | CODE | |
| LOW | tests/common_faiss_tests.py | 8 | CODE | |
| LOW | tests/common_faiss_tests.py | 8 | CODE | |
| LOW | tests/common_faiss_tests.py | 8 | CODE | |
| LOW | tests/common_faiss_tests.py | 8 | CODE | |
| LOW | tests/test_standalone_codec.py | 8 | CODE | |
| LOW | tests/test_clustering.py | 6 | CODE | |
| LOW | tests/test_clustering.py | 6 | CODE | |
| LOW | tests/test_clustering.py | 6 | CODE | |
| LOW | contrib/torch/clustering.py | 14 | CODE | |
| LOW | faiss/gpu/test/test_gpu_basics.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_basics.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_basics.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_basics.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_index_refs.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_index_ivfsq.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_index.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_index.py | 6 | CODE | |
| LOW | faiss/gpu/test/test_gpu_index.py | 6 | CODE | |
| 45 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/test_contrib.py | 773 | except ZeroDivisionError: | CODE |
| HIGH | tests/test_svs_py.py | 1676 | except OSError: | CODE |
| HIGH | tests/test_svs_py.py | 1790 | except OSError: | CODE |
| HIGH | tests/test_svs_py.py | 1878 | except OSError: | CODE |
| HIGH | tests/test_rabitq_fastscan.py | 370 | except RuntimeError: | CODE |
| HIGH | tests/test_factory.py | 35 | except RuntimeError: | CODE |
| HIGH | tests/test_fastscan_filter.py | 348 | except RuntimeError: | CODE |
| HIGH | tests/test_io.py | 577 | except Exception: | CODE |
| HIGH | tests/test_io.py | 609 | except Exception: | CODE |
| HIGH | tests/test_io.py | 641 | except Exception: | CODE |
| HIGH | tests/test_build_blocks.py | 219 | except Exception: | CODE |
| HIGH | tests/test_index_composite.py | 137 | except RuntimeError: | CODE |
| HIGH | tests/test_index_composite.py | 191 | except RuntimeError: | CODE |
| HIGH | tests/test_index_composite.py | 204 | except RuntimeError: | CODE |
| HIGH | tests/test_index_composite.py | 579 | except RuntimeError: | CODE |
| HIGH | tests/test_index_composite.py | 37 | except RuntimeError: | CODE |
| HIGH | faiss/gpu/test/test_multi_gpu.py | 52 | except RuntimeError: | CODE |
| HIGH | faiss/python/__init__.py | 603 | except NameError: | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_local_search_quantizer.py | 70 | CODE | |
| LOW | tests/test_graph_based.py | 806 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 180 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 561 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 710 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 757 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 809 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 850 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 934 | CODE | |
| LOW | tests/test_rabitq_fastscan.py | 1024 | CODE | |
| LOW | tests/test_ivf_flat_panorama.py | 825 | CODE | |
| LOW | tests/test_flat_panorama.py | 478 | CODE | |
| LOW | tests/test_flat_panorama.py | 721 | CODE | |
| LOW | tests/test_scalar_quantizer_correctness.py | 585 | CODE | |
| LOW | tests/test_scalar_quantizer_correctness.py | 636 | CODE | |
| LOW | tests/test_fastscan_filter.py | 31 | CODE | |
| LOW | tests/test_eden.py | 212 | CODE | |
| LOW | tests/test_sq_fastscan.py | 72 | CODE | |
| LOW | tests/test_sq_fastscan.py | 267 | CODE | |
| LOW | tests/test_merge_index.py | 23 | CODE | |
| LOW | tests/test_merge_index.py | 91 | CODE | |
| LOW | tests/test_refine_panorama.py | 463 | CODE | |
| LOW | tests/test_index_composite.py | 723 | CODE | |
| LOW | tests/test_hnsw_panorama.py | 355 | CODE | |
| LOW | tests/test_index.py | 140 | CODE | |
| LOW | tests/test_index.py | 574 | CODE | |
| LOW | tests/test_rabitq.py | 609 | CODE | |
| LOW | tests/test_rabitq.py | 635 | CODE | |
| LOW | tests/test_rabitq.py | 656 | CODE | |
| LOW | tests/test_rabitq.py | 688 | CODE | |
| LOW | tests/test_rabitq.py | 731 | CODE | |
| LOW | tests/test_rabitq.py | 752 | CODE | |
| LOW | tests/test_rabitq.py | 785 | CODE | |
| LOW | tests/test_rabitq.py | 828 | CODE | |
| LOW | tests/test_rabitq.py | 907 | CODE | |
| LOW | tests/test_index_accuracy.py | 415 | CODE | |
| LOW | tests/test_refine.py | 199 | CODE | |
| LOW | tests/test_search_params.py | 26 | CODE | |
| LOW | contrib/exhaustive_search.py | 60 | CODE | |
| LOW | contrib/datasets.py | 508 | CODE | |
| LOW | contrib/factory_tools.py | 10 | CODE | |
| LOW | contrib/factory_tools.py | 88 | CODE | |
| LOW | contrib/big_batch_search.py | 237 | CODE | |
| LOW | contrib/big_batch_search.py | 219 | CODE | |
| LOW | faiss/gpu/test/test_tiebreak_repro.py | 112 | CODE | |
| LOW | faiss/gpu/test/torch_test_contrib_gpu.py | 288 | CODE | |
| LOW | faiss/gpu/test/torch_test_contrib_gpu.py | 424 | CODE | |
| LOW | faiss/gpu/test/test_gpu_index_ivfsq.py | 113 | CODE | |
| LOW | benchs/bench_hybrid_cpu_gpu.py | 225 | CODE | |
| LOW | benchs/bench_hybrid_cpu_gpu.py | 292 | CODE | |
| LOW | benchs/bench_quantizer.py | 42 | CODE | |
| LOW | benchs/bench_pq_tables.py | 19 | CODE | |
| LOW | benchs/bench_hnsw_prune_headroom.py | 53 | CODE | |
| LOW | benchs/bench_gpu_1bn.py | 705 | CODE | |
| LOW | benchs/bench_rabitq.py | 156 | CODE | |
| LOW | benchs/bench_eden.py | 89 | CODE | |
| LOW | benchs/bench_eden.py | 129 | CODE | |
| LOW | benchs/bench_eden.py | 351 | CODE | |
| LOW | benchs/bench_eden.py | 501 | CODE | |
| LOW | benchs/bench_fw/optimize.py | 130 | CODE | |
| 22 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/test_ivf_flat_panorama.py | 0 | test correctness with various n_levels parameter values | STRING |
| HIGH | tests/test_flat_panorama.py | 0 | test correctness with various n_levels parameter values | STRING |
| HIGH | tests/test_refine_panorama.py | 0 | test correctness with various n_levels parameter values | STRING |
| HIGH | tests/test_ivf_flat_panorama.py | 0 | test edge case: more levels than dimension naturally supports | STRING |
| HIGH | tests/test_flat_panorama.py | 0 | test edge case: more levels than dimension naturally supports | STRING |
| HIGH | tests/test_refine_panorama.py | 0 | test edge case: more levels than dimension naturally supports | STRING |
| HIGH | tests/test_ivf_flat_panorama.py | 0 | test id selectors with dataset smaller than batch size | STRING |
| HIGH | tests/test_flat_panorama.py | 0 | test id selectors with dataset smaller than batch size | STRING |
| HIGH | tests/test_refine_panorama.py | 0 | test id selectors with dataset smaller than batch size | STRING |
| HIGH | tests/test_ivf_flat_panorama.py | 0 | test adding vectors incrementally in multiple batches | STRING |
| HIGH | tests/test_flat_panorama.py | 0 | test adding vectors incrementally in multiple batches | STRING |
| HIGH | tests/test_refine_panorama.py | 0 | test adding vectors incrementally in multiple batches | STRING |
| HIGH | tests/test_ivf_flat_panorama.py | 0 | test the correctness of the ratio of dimensions scanned | STRING |
| HIGH | tests/test_flat_panorama.py | 0 | test the correctness of the ratio of dimensions scanned | STRING |
| HIGH | tests/test_refine_panorama.py | 0 | test the correctness of the ratio of dimensions scanned | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | INSTALL.md | 118 | ## Step 1: invoking CMake | COMMENT |
| LOW | INSTALL.md | 170 | ## Step 2: Invoking Make | COMMENT |
| LOW | INSTALL.md | 205 | ## Step 3: Building the python bindings (optional) | COMMENT |
| LOW | INSTALL.md | 216 | ## Step 4: Installing the C++ library and headers (optional) | COMMENT |
| LOW | INSTALL.md | 227 | ## Step 5: Testing (optional) | COMMENT |
| LOW | .github/workflows/index-io-backward-compatibility.yml | 23 | # Step 1: Build with CMake and write files | COMMENT |
| LOW | .github/workflows/index-io-backward-compatibility.yml | 48 | # Step 2: Install conda faiss-cpu in a clean environment and read files | COMMENT |
| LOW | .github/workflows/index-io-backward-compatibility.yml | 85 | # Step 1: Install conda faiss-cpu in a clean environment and write files | COMMENT |
| LOW | .github/workflows/index-io-backward-compatibility.yml | 114 | # Step 2: Build with CMake and read files | COMMENT |
| LOW | faiss/impl/RaBitQuantizer.cpp | 127 | // Step 1: Compute 1-bit quantization and base factors | COMMENT |
| LOW | faiss/impl/RaBitQuantizer.cpp | 167 | // Step 2: Compute ex-bits quantization (if nb_bits > 1) | COMMENT |
| LOW | faiss/impl/RaBitQuantizerMultiBit.cpp | 263 | // Step 1: Compute L2 norm of residual | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 278 | // Step 2: Normalize residual | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 284 | // Step 3: Take absolute value | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 290 | // Step 4: Find optimal scaling factor | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 293 | // Step 5: Quantize to ex_bits | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 304 | // Step 6: Handle negative dimensions (flip bits) | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 312 | // Step 7: Pack codes into byte array | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 273 | // Step 1: coarse distance matrix | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 297 | // Step 2: coarse top-nprobe | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 308 | // Step 3: IVF scan | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 340 | // Step 4: merge | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 439 | // Step 1: build per-(query, probe) PQ lookup tables. | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 454 | // Step 2: scan the assigned inverted lists with 8-bit ADC. The small-list | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 477 | // Step 3: merge per-list top-k into the final top-k. | COMMENT |
| LOW⚡ | faiss/gpu_metal/MetalDistance.mm | 605 | // Step 1: per-query M*256 term (once per batch, not per probe). | COMMENT |
| LOW⚡ | faiss/gpu_metal/MetalDistance.mm | 610 | // Step 2: fused LUT-combine + list scan with exact running top-k. | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 640 | // Step 3: merge the nprobe per-list top-k in rounds of groupSize lists | COMMENT |
| LOW | faiss/docs/simd_dynamic_dispatch_migration.md | 97 | ### Step 1: Templatize on SIMDLevel | COMMENT |
| LOW | faiss/docs/simd_dynamic_dispatch_migration.md | 138 | ### Step 2: Split into per-SIMD translation units | COMMENT |
| LOW | faiss/docs/simd_dynamic_dispatch_migration.md | 195 | ### Step 3: Wire up dispatch | COMMENT |
| LOW | faiss/docs/simd_dynamic_dispatch_migration.md | 247 | ### Step 4: Register in build system | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | CMakeLists.txt | 8 | # ============================================================================= | COMMENT |
| MEDIUM | CMakeLists.txt | 20 | # ============================================================================= | COMMENT |
| MEDIUM⚡ | tests/test_rabitq.py | 486 | # ============================================================================== | COMMENT |
| MEDIUM⚡ | tests/test_rabitq.py | 488 | # ============================================================================== | COMMENT |
| MEDIUM | faiss/CMakeLists.txt | 11 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/CMakeLists.txt | 15 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/CMakeLists.txt | 100 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/CMakeLists.txt | 562 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/CMakeLists.txt | 567 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/gpu/CMakeLists.txt | 7 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/gpu/CMakeLists.txt | 19 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/gpu/test/CMakeLists.txt | 7 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/gpu/test/CMakeLists.txt | 19 | # ============================================================================= | COMMENT |
| MEDIUM | faiss/utils/simd_impl/partitioning_simdlib256.h | 47 | // ── Per-TU SIMD type aliases ────────────────────────────────────────── | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | .github/workflows/index-io-backward-compatibility.yml | 23 | # Step 1: Build with CMake and write files | COMMENT |
| LOW | .github/workflows/index-io-backward-compatibility.yml | 48 | # Step 2: Install conda faiss-cpu in a clean environment and read files | COMMENT |
| LOW | .github/workflows/index-io-backward-compatibility.yml | 85 | # Step 1: Install conda faiss-cpu in a clean environment and write files | COMMENT |
| LOW | .github/workflows/index-io-backward-compatibility.yml | 114 | # Step 2: Build with CMake and read files | COMMENT |
| LOW | faiss/impl/RaBitQuantizer.cpp | 127 | // Step 1: Compute 1-bit quantization and base factors | COMMENT |
| LOW | faiss/impl/RaBitQuantizer.cpp | 167 | // Step 2: Compute ex-bits quantization (if nb_bits > 1) | COMMENT |
| LOW | faiss/impl/RaBitQuantizerMultiBit.cpp | 263 | // Step 1: Compute L2 norm of residual | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 278 | // Step 2: Normalize residual | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 284 | // Step 3: Take absolute value | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 290 | // Step 4: Find optimal scaling factor | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 293 | // Step 5: Quantize to ex_bits | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 304 | // Step 6: Handle negative dimensions (flip bits) | COMMENT |
| LOW⚡ | faiss/impl/RaBitQuantizerMultiBit.cpp | 312 | // Step 7: Pack codes into byte array | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 273 | // Step 1: coarse distance matrix | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 297 | // Step 2: coarse top-nprobe | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 308 | // Step 3: IVF scan | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 340 | // Step 4: merge | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 439 | // Step 1: build per-(query, probe) PQ lookup tables. | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 454 | // Step 2: scan the assigned inverted lists with 8-bit ADC. The small-list | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 477 | // Step 3: merge per-list top-k into the final top-k. | COMMENT |
| LOW⚡ | faiss/gpu_metal/MetalDistance.mm | 605 | // Step 1: per-query M*256 term (once per batch, not per probe). | COMMENT |
| LOW⚡ | faiss/gpu_metal/MetalDistance.mm | 610 | // Step 2: fused LUT-combine + list scan with exact running top-k. | COMMENT |
| LOW | faiss/gpu_metal/MetalDistance.mm | 640 | // Step 3: merge the nprobe per-list top-k in rounds of groupSize lists | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test_index_accuracy.py | 252 | index.nprobe = 4 # hopefully more robust than 1 | CODE |
| MEDIUM | tests/test_index_accuracy.py | 310 | index.nprobe = 4 # hopefully more robust than 1 | CODE |
| MEDIUM | faiss/IndexPQ.h | 118 | /// statistics are robust to internal threading, but not if | COMMENT |
| MEDIUM | faiss/IndexIVFPQ.h | 186 | /// statistics are robust to internal threading, but not if | COMMENT |
| MEDIUM | faiss/impl/PanoramaStats.h | 17 | /// Statistics are not robust to internal threading nor to | COMMENT |
| MEDIUM | faiss/gpu/test/test_gpu_index.py | 365 | # precomputed codes also utilize the coarse quantizer | COMMENT |
| LOW | faiss/python/array_conversions.py | 94 | # TODO: once deprecated classes are removed, remove the dict and just use | COMMENT |
| MEDIUM | faiss/utils/hamming_distance/hamming_computer-avx512.h | 16 | // GenHammingComputer classes leverage SSE/AVX2 intrinsics. | COMMENT |
| MEDIUM | faiss/utils/hamming_distance/hamming_computer-avx2.h | 14 | // GenHammingComputer classes leverage SSE/AVX2 intrinsics. | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_io.py | 577 | except Exception: | CODE |
| LOW | tests/test_io.py | 609 | except Exception: | CODE |
| LOW | tests/test_io.py | 641 | except Exception: | CODE |
| LOW | tests/test_build_blocks.py | 219 | except Exception: | CODE |
| LOW | …ndex_io_backward_compatibility/cmake_conda_io_utils.py | 255 | except Exception as e: | CODE |
| LOW | …ndex_io_backward_compatibility/cmake_conda_io_utils.py | 288 | except Exception as e: | CODE |
| LOW | …ndex_io_backward_compatibility/cmake_conda_io_utils.py | 318 | except Exception as e: | CODE |
| LOW | …ndex_io_backward_compatibility/cmake_conda_io_utils.py | 348 | except Exception as e: | CODE |
| LOW | contrib/rpc.py | 145 | except Exception as e: | CODE |
| LOW⚡ | faiss/gpu/test/test_index_cpu_to_gpu.py | 43 | except Exception as e: | CODE |
| LOW⚡ | faiss/gpu/test/test_index_cpu_to_gpu.py | 59 | except Exception as e: | CODE |
| LOW | faiss/gpu/test/test_index_cpu_to_gpu.py | 97 | except Exception as e: | CODE |
| MEDIUM | faiss/gpu/test/test_index_cpu_to_gpu.py | 40 | def verify_throws_not_implemented_exception(self, factory_string): | CODE |
| MEDIUM | faiss/gpu/test/test_index_cpu_to_gpu.py | 50 | def verify_clones_successfully( | CODE |
| MEDIUM | faiss/gpu/test/test_index_cpu_to_gpu.py | 92 | def test_with_flag_set_to_false(self): | CODE |
| LOW | benchs/bench_all_ivf/parse_bench_all_ivf.py | 139 | except Exception as e: | CODE |
| LOW | demos/offline_ivf/offline_ivf.py | 617 | except Exception: | CODE |
| MEDIUM | demos/offline_ivf/offline_ivf.py | 605 | def _knn_function(self, xq, xb, k, metric, thread_id=None): | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | tests/test_graph_based.py | 404 | # Create a vector with NaN in the first component | COMMENT |
| MEDIUM | tests/test_flat_panorama.py | 686 | # Create a random permutation | COMMENT |
| MEDIUM | tests/test_wheel_smoke_gpu.py | 30 | # This file is the faiss-gpu wheel smoke test. It also gets collected by | COMMENT |
| MEDIUM | tests/test_hnsw_panorama.py | 437 | # Create a permutation (reverse order for simplicity) | COMMENT |
| MEDIUM | tests/test_index.py | 868 | # Create the dataset | COMMENT |
| MEDIUM | tests/test_search_params.py | 167 | # Create a mask of valid IDs (those in subset) | COMMENT |
| MEDIUM | faiss/gpu/hipify.sh | 42 | # Create a backup of the original gpu directory | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | contrib/client_server.py | 65 | def set_nprobe(self, nprobe: int) -> None: | CODE |
| LOW | contrib/client_server.py | 68 | def set_omp_num_threads(self, nt: int) -> None: | CODE |
| LOW | faiss/python/__init__.py | 175 | logger = logging.getLogger(__name__) | CODE |
| LOW | faiss/python/loader.py | 107 | logger = logging.getLogger(__name__) | CODE |
| LOW | benchs/bench_fw/optimize.py | 20 | logger = logging.getLogger(__name__) | CODE |
| LOW | benchs/bench_fw/benchmark.py | 32 | logger = logging.getLogger(__name__) | CODE |
| LOW | benchs/bench_fw/index.py | 39 | logger = logging.getLogger(__name__) | CODE |
| LOW | benchs/bench_fw/benchmark_io.py | 24 | logger = logging.getLogger(__name__) | CODE |
| LOW | benchs/bench_fw/descriptors.py | 16 | logger = logging.getLogger(__name__) | CODE |
| LOW | benchs/bench_fw/utils.py | 19 | logger = logging.getLogger(__name__) | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_svs_py.py | 30 | # Check if LVQ/LeanVec support is available | COMMENT |
| LOW | tests/test_hnsw_panorama.py | 409 | # Check if this neighbor is still in the result set | COMMENT |
| LOW | faiss/python/class_wrappers.py | 274 | # Check if the attribute already exists (valid attribute) | COMMENT |
| LOW | faiss/python/class_wrappers.py | 276 | # Check if it exists on the instance or class | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | contrib/big_batch_search.py | 237 | CODE | |
| LOW | faiss/gpu/test/bench_approaches.py | 116 | CODE | |
| LOW | benchs/kmeans_mnist.py | 35 | CODE | |
| LOW | benchs/bench_hnsw_prune_headroom.py | 53 | CODE | |
| LOW | benchs/bench_fw/utils.py | 178 | CODE | |
| LOW | demos/offline_ivf/tests/testing_utils.py | 29 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | contrib/vecs_io.py | 85 | Memory-mapped iterator over chunked .bvecs files. Iterates through all chunk files in order (chunk_0000.bvecs, | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | faiss/impl/ClusteringInitialization.h | 46 | /// Example usage: | COMMENT |
| LOW | faiss/utils/extra_distances.h | 63 | /// Example usage: | COMMENT |
| LOW | demos/index_pq_flat_separate_codes_from_codebook.py | 256 | # # Example usage: | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/test_build_blocks.py | 335 | # make sure to test extreme cases | COMMENT |
| LOW | tests/test_index_accuracy.py | 583 | # make sure to test below and above | COMMENT |
| MEDIUM | contrib/rpc.py | 10 | This code is for demonstration purposes only, and does not include certain | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| MEDIUM | benchs/bench_fw/index.py | 149 | CODE | |
| MEDIUM | benchs/bench_fw/index.py | 150 | CODE |