I've coded a small clustering algorithm for time signals using kmeans, which works ok (gives acceptable results).
However, kmeans uses the sum of squared differences. I would like to be able to input instead my own measure of difference, but there doesn't seem to be a way provided by the library to do that.
What would be the easiest way to achieve this? Any other python library which may provide me some way to input instead my own function to define the distance? Or I guess I could instead re-implement the algorithm myself, but I'd rather keep the sci-kit one (since they provide functionalities I want to use such as parallel processing).