diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2020-07-22 16:27:50 +0200 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2020-07-22 16:27:50 +0200 |
commit | db0040dbe91729b9bd78c40b4be75068b1e6968a (patch) | |
tree | 0a7545088209f124d9767a389cbe7f7306b66d15 /demo.py | |
parent | 663122dabf0498ae9522b0f53939e21ab64d052b (diff) |
Vastly improve the quality of clusterings.
Setting a minimum cluster size prevents the algorithm from trying to 'cheat' by creating many 3- or 4-colour clusters. This was especially bad when PCA would determine only two basis functions were necessary (the third one being essentially random), causing massive reconstruction errors.
Diffstat (limited to 'demo.py')
-rw-r--r-- | demo.py | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -17,7 +17,7 @@ if __name__ == '__main__': print('Clustering...') before = clustering.root.total_reconstruction_error() - clustering.optimise(8) + clustering.optimise() after = clustering.root.total_reconstruction_error() print('Error before: %g' % before) |