Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@KIwabuchi
Copy link
Member

@KIwabuchi KIwabuchi commented Jan 30, 2025

Overview

  • Add get_neighbors() and get_neighbors_with_features() in both simple and advanced API.
  • Updated dnnd_simple.cpp to use those new methods.
  • Add three executables for advanced API:
    • dnnd_advance_index_build: builds KNN index in Metall.
    • dnnd_advance_get_neighbors: loads an already built index and calls the new get_neighbor* functions.
    • dnnd_advance_query: loads an already built index and runs queries

Advanced API new examples:

# Construct k-NN index (k=4).
mpirun -np 2 ./examples/dnnd_advance_index_build -k 4 -f l2 -p wsv ../examples/datasets/point_5-4.txt -d /dev/shm/metall-datastore

# Show neighbors of point 0, 2, and 3 from the k-NN index.
mpirun -np 2 ./examples/dnnd_advance_get_neighbors -d ./dev/shm/metall-datastore -p 0,2,3

# Run queries. Find 4 nearest neighbors per query source point.
mpirun -np 2 ./examples/dnnd_advance_query -d ./dstore/ -f l2 -n 4 -q ../examples/datasets/query_5-4.txt 

@KIwabuchi KIwabuchi merged commit 4997ead into LLNL:v0.3-dev Feb 6, 2025
1 check passed
@KIwabuchi KIwabuchi deleted the feature/dnnd_fast_query branch February 6, 2025 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant