xvector_pytorch
xvector_pytorch copied to clipboard
hello,i have a question is that how to extract embedding a,b
from you code xvector-gpu.ipynb , the net construction is :+1: Sequential( (0): TDNN() (1): TDNN() (2): TDNN() (3): TDNN() (4): TDNN() (5): StatsPooling() (6): FullyConnected( (hidden1): Linear(in_features=3000, out_features=512, bias=True) (hidden2): Linear(in_features=512, out_features=512, bias=True)))
but the code "output= net(torch.tensor(X_test[100:120]).cuda())" is extract embedding b, how extract embedding a? and i dont understand why you spit X_text from 100:120 ?
thanks
Hey, what do you mean by embedding a exactly ? The embedding from the first dense layer ? Also ive chosen 20 frames from 100 to 120 randomly to extract embedding on, it could receive sequance of mfcc of any length (80:100, 10:60 , 0:20 etc)
yes ,thanks,my friend, you code help me . now ,i start use my trainset to train this net. embedding a is hidden1 's output , and embedding b is hidden 2 ' s output and i find out how to extact embedding b from you code but confusion of how to embedding a and i have other question is what time you train this net ?
hey, currently is not comfortable to extract it, im working on version that will be more continent, meanwhile you could try pyannote package
Cool, I hope the author can make a use of pyannote to do x-vector tutorial