You can put your vectors in a container with spatial support, such as R-tree or kd tree or PK-Tree .
Thus, you can find points without repeating your entire data set, just by looking at several neighboring cells. Do not forget that you need to search not only in one cell, but also in neighboring cells, and in multidimensional space - many neighbors.
Update: You still need to manually measure the distance. However, you will not need to iterate over all the vectors.
- , , , N.
( ) - . , , vX, N . vX N- ( ) vX , , N. , , . - , ( PK-, ).
( , ) - , . node, vX, N vX , N- , - , node. , , . ( , vX ), - 100k .