I am not sure it is what you want but you could use:

K = radius_neighbors_graph(X, radius, mode='distance')
K.data **= 2
K.data *= -gamma
np.exp(K.data, out=K.data)

no?

Alex

On Sun, Jan 22, 2012 at 9:34 PM, Andreas <[email protected]> wrote:
> Hi everybody.
> While reviewing the label propagation PR, I thought about the pairwise
> rbf functions.
> Would it be possible to compute an sparse, approximate RBF kernel matrix
> using ball trees?
> The idea would be that if the distance between two points is some
> "large" multiple of gamma, the kernel can be assumed
> to be zero.
> Do you think this is feasible to implement and helpful for real data?
>
> Cheers,
> Andy
>
> ------------------------------------------------------------------------------
> Try before you buy = See our experts in action!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-dev2
> _______________________________________________
> Scikit-learn-general mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

------------------------------------------------------------------------------
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-dev2
_______________________________________________
Scikit-learn-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/scikit-learn-general

Reply via email to