Snowdar / asv-subtools

An Open Source Tools for Speaker Recognition
Apache License 2.0
590 stars 135 forks source link

Mixup object has no attributor 'lam' #29

Closed mxer closed 3 years ago

mxer commented 3 years ago

Hi, Thanks for great job. I have tried to use Mixup Learning Strategies, but I got an Error which says: Mixup object has no attribute 'lam' I think this may be an implementation bug.

1017549629 commented 3 years ago

Hi, how did you use Mixup Learning Strategies. When I use it in asv-subtools, I don't encounter such problems.

mxer commented 3 years ago

Hi, how did you use Mixup Learning Strategies. When I use it in asv-subtools, I don't encounter such problems.

Hi, I added one line in https://github.com/Snowdar/asv-subtools/blob/master/pytorch/launcher/runEcapaXvector.py#:~:text=model%27s%20__init__(model_params).-,model_params%20%3D,-%7B as follow: "mixup":True, "mixup_alpha":0.1,

1017549629 commented 3 years ago

Thanks, I see, it is indeed a bug. We will fix it next time. In fact , it should add x = self.auto(self.mixup, x) after "pooling layer". You can fix it by adding it before this line: https://github.com/Snowdar/asv-subtools/blob/1ea98945b50b6401fd28627e760f6e66a08a22e7/pytorch/model/ecapa-tdnn-xvector.py#L274.

mxer commented 3 years ago

Thanks, I see, it is indeed a bug. we will fix it next time. In fact , it should add x = self.auto(self.mixup, x) after "pooling layer" .You can add it before this line

https://github.com/Snowdar/asv-subtools/blob/1ea98945b50b6401fd28627e760f6e66a08a22e7/pytorch/model/ecapa-tdnn-xvector.py#L274

.

I have tried and it works, thank you very much