method_nnd function

An internal function to use the NN descent algorithm via the rnndescent package.