-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
train.kknn() fails on this data set #19
Comments
Hi @KlausVigo , any thoughts on this? |
Hi @kenahoo , On my machine your code is working, so I can't really reproduce your problem.
Regards, |
Hi Klaus, Actually, it seems to be non-deterministic. Here are a few runs in a row:
My session info:
|
I took R (mostly) out of the chain, and it looks like it's non-deterministic at the C level. Stepping through with the
I also noticed some mismatches between the order of argument names that
Any chance this is the issue? |
Hi @kenahoo, |
Hi @KlausVigo , I think that fixes the problem indeed. Curiously, I could only get this problem to manifest when running R interactively, not through Rscript. Maybe memory initialization is different in that case or something. Thanks. |
Here is a data set on which
train.knn()
fails:The error is happening because of the return value of
dmEuclid
in the C code. When I step through in the R debugger, I see this:I'm guessing this is either uninitialized memory or an overflow/underflow problem.
The text was updated successfully, but these errors were encountered: