ShobiStassen / PARC

MIT License
41 stars 11 forks source link

Added class parameter for pre-computed nearest neighbor graph. #12

Closed tommycelsius closed 4 years ago

tommycelsius commented 4 years ago

Improvements: Added a class parameter for a pre-computed nearest neighbor graph matrix (i.e., the CSR array used by PARC). We use adaptive neighbor graphs, where k is not the same for all elements, so this functionality is essential for us to use PARC.

Fixes: Within run_toobig_subPARC(), the line hnsw = self.make_knn_struct(too_big=True, big_cluster=X_data) wasn't working because self.make_knn_struct() returned None. It returns the hnsw index now instead.