Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inquiry about the Sphereface2 loss. #374

Open
JuseokSeong opened this issue Oct 17, 2024 · 1 comment
Open

Inquiry about the Sphereface2 loss. #374

JuseokSeong opened this issue Oct 17, 2024 · 1 comment
Assignees

Comments

@JuseokSeong
Copy link

Thank you for the nice work!

I wonder if it is possible to use the universal confidence threshold b proposed in SphereFace2 as an actual threshold?

We set -b/s as the threshold and compared it with the similarity score. However, it does not yield good performance.
The following code explains the method I described.
self.fun_g(cos, self.t) > -self.bias[0][0] / self.scale -> Samples predicted as positive
self.fun_g(cos, self.t) < -self.bias[0][0] / self.scale -> Samples predicted as negative
(name of these variables is same in https://github.com/wenet-e2e/wespeaker/blob/master/wespeaker/models/projections.py)

If there are any related codes or methods, please let me know.
Thank you.

@Hunterhuan
Copy link
Collaborator

Thank you for the nice work!

I wonder if it is possible to use the universal confidence threshold b proposed in SphereFace2 as an actual threshold?

We set -b/s as the threshold and compared it with the similarity score. However, it does not yield good performance. The following code explains the method I described. self.fun_g(cos, self.t) > -self.bias[0][0] / self.scale -> Samples predicted as positive self.fun_g(cos, self.t) < -self.bias[0][0] / self.scale -> Samples predicted as negative (name of these variables is same in https://github.com/wenet-e2e/wespeaker/blob/master/wespeaker/models/projections.py)

If there are any related codes or methods, please let me know. Thank you.

Thank you for your attention to this work.

In my opinion, the universal confidence threshold b can only serve as the boundary between speakers in the training set. During evaluation, the speakers don't has overlap with spks in training set, so the threshold should be set according to actual needs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants