Orange Forum • View topic - K-Means Clustering Bug

K-Means Clustering Bug

Report bugs (or imagined bugs).
(Archived/read-only, please use our ticketing system for reporting bugs and their discussion.)
Forum rules
Archived/read-only, please use our ticketing system for reporting bugs and their discussion.

K-Means Clustering Bug

Postby Alfred » Wed Sep 19, 2007 21:27

I cannot run the K-means Clustering widget due to the following errors:

Unhandled exception of type occured at 16:25:46:
File: in line 510
Function name: processSignals
Code: handler(value)
File: in line 129
Function name: setData
Code: self.cluster()
File: in line 104
Function name: cluster
Code: = orngCluster.MClustering(examples, self.K,
File: in line 198
Function name: __init__
Code: (a,b,c,d,e,f) = orngCRS.MCluster(distrlist,k,metric)
Exception type:
Exception value: MCluster() takes exactly 4 arguments (3 given)

Any help?

Postby Janez » Wed Sep 19, 2007 22:10

orngCRS is, unlike the rest of Orange, prepared with Swig, which seems not to care much about backward compatibility. We've find a problem (I think it was exactly this one) in k-means and fixed it in May already.

If you use Windows binaries, either download a new snapshot or replace c:\python25\python\lib\site-packages\_orngCRS.pyd with the one from ... rngCRS.pyd (replace 25 with 24 or 23 if you have an older Python). Orange should not be running when you do this.

If you build the source yourself: the affected file is source/orngCRS/src/Clusting_wrap.cpp. Check that it does not contain "%typemap(in,numinputs=0) struct CFInfo *OutValue {" (it should have this same string, but without 'struct').

Please tell me if it worked.


Postby Alfred » Thu Sep 20, 2007 17:09

Thank you for the quick reply. It works fine.
I downloaded the file from ... rngCRS.pyd and replaced the one in C:\Python25\Lib\site-packages\orange. I originally used orange-w-python-0.9.66-py2.5.exe for installation.

Return to Bugs