albert_pytorch
albert_pytorch copied to clipboard
tf_path in the english model
Hello,
I wanted to ask for the purpose of adding tf_path = tf_path + "/variables/variables" in the english model. There's no analogous tf_path modification in the chinese version of the script. Removing this line seems to fix my issue with converting the model.
https://github.com/lonePatient/albert_pytorch/blob/3da2ebc5d71ce44be1123344d2f629fc21ffb01b/albert_english_pytorch/model/modeling_albert.py#L50
If it's indeed a bug, I've created a PR with a fix. If not, sorry for the trouble.
Thank you :)
@Porcupine96 Adding tf_path = tf_path + "/variables/variables" is for converting the weight of th_hub to the weight of pytorch.