btel / SpikeSort

Spike sorting library implemented in Python/NumPy/PyTables
http://spike-sort.readthedocs.org
Other
27 stars 12 forks source link

type consistency in spike_features datastructure #90

Closed belevtsoff closed 11 years ago

belevtsoff commented 11 years ago

According to docs, 'names' entry in the spike_features dictionary must be a list of strings. Most fet* methods conform to this. However, features.combine returns numpy array of names. Moreover, ClusterAnalyzer._cluster relies on the fact that feature_data['names'] is actually a numpy array and uses advanced indexing which doesn't work on lists. This didn't cause many problems before feature hiding functionality was implemented

Because numpy arrays are generally not very well suited for storing variable length objects, It maybe worth accepting a "list of strings" convention completely.

@btel or was that made on purpose?