tslearn icon indicating copy to clipboard operation
tslearn copied to clipboard

Support for silhouette_samples() functionalities like sklearn.

Open srimantacse opened this issue 1 year ago • 5 comments

Is there any support for silhouette_samples() functionalities as sklearn has.

srimantacse avatar May 18 '23 10:05 srimantacse

Hi,

We don't have support for silhouette_samples at the moment.

In terms of implementation, given the current implementation of silhouette_score (https://github.com/tslearn-team/tslearn/blob/main/tslearn/clustering/utils.py#L66) that heavily relies on sklearn's implem, it should be pretty much the same for one willing to adapt silhouette_samples:

  1. compute cross-similarity metrics between points
  2. rely on sklearn's implementation using metric="precomputed"

Anyone is welcome to open a PR on the topic.

rtavenar avatar May 22 '23 07:05 rtavenar

@rtavenar thanks for the help. Able to get the sample score as you mentioned the steps. Thanks again.

srimantacse avatar May 23 '23 11:05 srimantacse

@srimantacse would you be willing to contribute your code to tslearn ? If so, we would be happy to help you along the process.

rtavenar avatar May 23 '23 12:05 rtavenar

@rtavenar please share me the process, I will do it. Request to give me some time considering my schedule. Share me the process.

srimantacse avatar May 25 '23 06:05 srimantacse

You can find info there: https://github.com/tslearn-team/tslearn/blob/main/CONTRIBUTING.md#more-details-on-pull-requests

No problem if it takes some time, of course, it's always great to welcome new contributors

rtavenar avatar May 25 '23 07:05 rtavenar