VideoTransformer-pytorch icon indicating copy to clipboard operation
VideoTransformer-pytorch copied to clipboard

How to load Tensorflow checkpoints?

Open realgump opened this issue 2 years ago • 3 comments

Hello, thanks for your great work. I have successfully trained the Vivit. However, only several checkpoints are available. In another issue, you have mentioned that the pre-trained models are from the original repo of Google. Could you kindly share the code for conversion or tell the method?

realgump avatar Jul 26 '22 12:07 realgump

@realgump you can check this link https://github.com/rwightman/pytorch-image-models/blob/7430a85d07a7f335e18c2225fda4a5e7b60b995c/timm/models/vision_transformer.py#L52.

mx-mark avatar Jul 30 '22 00:07 mx-mark

Hi @mx-mark Referring to Issue#19, Could you please give link of the github repo which converts JAX .npz file to pytorch compatible .pth/.pt file. Thank you!

asif-hanif avatar Oct 10 '22 18:10 asif-hanif

@asif-hanif You can check this link https://github.com/asyml/vision-transformer-pytorch/blob/2d8828948e7ab122f5db11fd67cb7b46c6bb6823/src/checkpoint.py#L80.

mx-mark avatar Oct 13 '22 07:10 mx-mark