WeidiXie / VGG-Speaker-Recognition

Utterance-level Aggregation For Speaker Recognition In The Wild
362 stars 98 forks source link

problem with testing my own trained model #37

Closed aSafarpoor closed 5 years ago

aSafarpoor commented 5 years ago

hi. i found your code really complete and i tried to use is but: when i use your model called in "readme" to predict it works but when i try to use my own data with "python main.py .... " and then i want to use it for prediction , i found an error about not same shape , .... would you please help me about that?

aSafarpoor commented 5 years ago

my error is sth like this: ValueError: Layer #125 (named "gvlad_center_assignment"), weight <tf.Variable 'gvlad_center_assignment/kernel:0' shape=(7, 1, 512, 10) dtype=float32_ref> has shape (7, 1, 512, 10), but the saved weight has shape (12, 512, 7, 1)

do you have any idea please?

WeidiXie commented 5 years ago

Hi,

I assume you are not following my code exactly, either you change your input size or the backbone networks.

Check here, https://github.com/WeidiXie/VGG-Speaker-Recognition/blob/96351761a5fa68e2fca1d3d49181a7845f837253/src/model.py#L127

Your tensor shape to this layer should be something like: Batchsize x 7 x 1 x D

aSafarpoor commented 5 years ago

yeah,i change vlad size and it works. thank you for your answer