yjxiong / tsn-pytorch

Temporal Segment Networks (TSN) in PyTorch
BSD 2-Clause "Simplified" License
1.07k stars 308 forks source link

Need pre-trained kinetics weights for Pytorch #47

Open fmthoker opened 6 years ago

fmthoker commented 6 years ago

Hello everyone, Has anyone successfully converted kinetics pre-trained weights into Pytorch TSN?

ekazakos commented 6 years ago

Hi, did you have any luck with that?

pfabreu commented 6 years ago

I have .hdf5 files for TF/Keras if you want.

fmthoker commented 6 years ago

@pedro-abreu can you share them with me. Email address fmthoker@gmail.com

ekazakos commented 6 years ago

@pedro-abreu Thanks a lot, but Im using PyTorch atm. For anyone that may be interested, you can download the caffe pretrained weights and convert them to pytorch weights using parse_caffe.py in tsn-pytorch/tf_model_zoo/bninception.

pfabreu commented 6 years ago

@ekazakos Thanks man, I might switch to Pytorch eventually :). @fmthoker https://drive.google.com/drive/folders/13TaIjogd2ReNsKXNJ55o3_qsDWB5KlkM?usp=sharing here you go.

yjxiong commented 6 years ago

Thanks to folks! Do you mind sharing it to other users?

ekazakos commented 6 years ago

@yjxiong Sure, will do soon!

ekazakos commented 6 years ago

Everyone, you can find the pretrained Kinetics weights for TSN that I converted to work with PyTorch here: https://drive.google.com/drive/folders/1R4n8vSQJ0LtB1mPhhjMHEQrKj3UDQS1U?usp=sharing

Load the weights normally with:

state_dict = torch.load(pretrained)

If you are using Pytorch 0.4 do:

for k, v in state_dict.items():     state_dict[k] = torch.squeeze(v, dim=0)

yjxiong commented 6 years ago

@ekazakos

Thanks! Do you mind we sharing the files in the project website?

ekazakos commented 6 years ago

@yjxiong It is totally fine.

ahmedgamaleldin14 commented 5 years ago

Everyone, you can find the pretrained Kinetics weights for TSN that I converted to work with PyTorch here: https://drive.google.com/drive/folders/1R4n8vSQJ0LtB1mPhhjMHEQrKj3UDQS1U?usp=sharing

Load the weights normally with:

state_dict = torch.load(pretrained)

If you are using Pytorch 0.4 do:

for k, v in state_dict.items():     state_dict[k] = torch.squeeze(v, dim=0)

@ekazakos Hello, thanks for sharing the weights. Do you have RGB Difference pretrained weights as well? Another question, have you used BNInception or other architecture?

ekazakos commented 5 years ago

@AhmedGamal1496 Im really sorry for the very late answer, I do not know how I missed this one. I do not have RGB Difference. And yes I've used only BN-Inception.