You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is certainly of interest to me -- I had been planning something similar before the paper came out, and had already coded up a python version of NNDescent. That version is not parallel, but making it so would be interesting to try. One catch that comes to mind is that that implementation is currently using Numba instead of Cython for performance. Did the maintainers here have any strong feelings on Numba dependencies?
I’m happy to accept numba as a dependency (I have a branch moving our Cython k-means to numba. Using just numba would simplify our build and release process. )
I'll see what I can put together then. I can't make any promises on getting it done soon, but I will definitely put it in the queue of things to work on.
I chatted with @lmcinnes about this. It seems like this is slightly blocked on improved slicing of dask arrays with out-of-order indices. For example the following was inefficient
In [1]: importdask.arrayasdaIn [2]: x=da.random.random((1000000, 100), chunks=(10000, 100))
In [3]: importnumpyasnpIn [4]: index=np.arange(len(x))
In [5]: np.random.shuffle(index)
In [6]: %timey=x[index]
/home/mrocklin/Software/anaconda/bin/ipython:1: PerformanceWarning: Slicingwithanout-of-orderindexisgenerating9900timesmorechunks#!/home/mrocklin/Software/anaconda/bin/pythonCPUtimes: user4.48s, sys: 188ms, total: 4.67sWalltime: 4.68sIn [7]: y.numblocksOut[7]: (989999, 1)
We've started to make progress on this on the Dask side: (dask/dask#3808 for slicing performance with as shuffled array).
@lmcinnes do you have a rough sketch of the next steps for a parallel / distributed pynndescent? On a brief examination, the random projections would be the first thing? I'm interested in working on this a bit.
Activity
lmcinnes commentedon Apr 10, 2018
I believe an approximate version of this is parallelizable. Some of the relevant techniques are described in this paper: http://www.sysml.cc/doc/105.pdf
This is certainly of interest to me -- I had been planning something similar before the paper came out, and had already coded up a python version of NNDescent. That version is not parallel, but making it so would be interesting to try. One catch that comes to mind is that that implementation is currently using Numba instead of Cython for performance. Did the maintainers here have any strong feelings on Numba dependencies?
TomAugspurger commentedon Apr 11, 2018
Great!
I’m happy to accept numba as a dependency (I have a branch moving our Cython k-means to numba. Using just numba would simplify our build and release process. )
lmcinnes commentedon Apr 11, 2018
I'll see what I can put together then. I can't make any promises on getting it done soon, but I will definitely put it in the queue of things to work on.
TomAugspurger commentedon Apr 11, 2018
Skimming the paper at http://www.sysml.cc/doc/105.pdf
https://github.com/lmcinnes/pynndescent would be great to make dask-friendly and include in dask-ml. If possible I'd like to re-use it for a top-level KNeighborsClassfier/Regressor API, and inside SpectralClustering (as an alternative to K-Means).
mrocklin commentedon Jul 15, 2018
I chatted with @lmcinnes about this. It seems like this is slightly blocked on improved slicing of dask arrays with out-of-order indices. For example the following was inefficient
jakirkham commentedon Jul 15, 2018
So would solving issue ( dask/dask#3409 ) address this?
mrocklin commentedon Jul 15, 2018
mrocklin commentedon Jul 15, 2018
Although it may also be that we can improve things today if we index directly many times, but make sure that the index is sorted.
mrocklin commentedon Jul 17, 2018
I've laid out a plan in dask/dask#3409 (comment) to improve things a bit. That should be accessible for others to contribute if they're interested.
TomAugspurger commentedon Aug 29, 2018
We've started to make progress on this on the Dask side: (dask/dask#3808 for slicing performance with as shuffled array).
@lmcinnes do you have a rough sketch of the next steps for a parallel / distributed pynndescent? On a brief examination, the random projections would be the first thing? I'm interested in working on this a bit.