We are getting the following error in cluster.py
# python /mnt/www/drupal/sites/all/modules/memetracker/cluster.py /mnt/www/drupal/sites/default/files/memetracker_data.txt 0.2
Traceback (most recent call last):
File "/mnt/www/drupal/sites/all/modules/memetracker/cluster.py", line 39, in
y = array(p,'d')
NameError: name 'array' is not defined
After some poking around, we changed line 39 to:
y = numpy.array(p,'d')
This started giving us some good results on the command line, as well as with our Drupal installation. We are getting memes too.
# python /root/cluster.py /mnt/www/drupal/sites/default/files/memetracker_data.txt 0.9
1,0,0.6984175;4,3,0.7810875;-2,-1,0.862191625;5,6,0.87738925;
We had some difficulties installing Numeric but eventually got it installed and it seemed to work properly when called from Python however Memetracker did not work. We read that numpy had replaced Numeric which is why we decided to try to use numpy instead.
Is this OK? Have we installed Numeric incorrectly? Are we asking for trouble using Numpy instead of Numeric?