affeaa847d58416d5b9372cae521deb4550ce54d,torchreid/models/resnext.py,,init_pretrained_weights,#Any#Any#,190
Before Change
model_dict.update(pretrain_dict)
model.load_state_dict(model_dict)
print("Initialized model with pretrained weights from {}".format(model_url))
print("Imagenet weights unavailable")
def resnext50_32x4d(num_classes, loss, pretrained="imagenet", **kwargs):
model = ResNeXt(
After Change
pretrain_dict = model_zoo.load_url(model_url)
model_dict = model.state_dict()
pretrain_dict = {k: v for k, v in pretrain_dict.items() if k in model_dict and model_dict[k].size() == v.size()}
model_dict.update(pretrain_dict)
model.load_state_dict(model_dict)
print("Initialized model with pretrained weights from {}".format(model_url))
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 6
Instances Project Name: KaiyangZhou/deep-person-reid
Commit Name: affeaa847d58416d5b9372cae521deb4550ce54d
Time: 2018-11-23
Author: k.zhou@qmul.ac.uk
File Name: torchreid/models/resnext.py
Class Name:
Method Name: init_pretrained_weights
Project Name: brightmart/text_classification
Commit Name: 95d839a5e3a03478728110d116adf0a4c9d49a34
Time: 2018-11-17
Author: brightmart@hotmail.com
File Name: a02_TextCNN/p7_TextCNN_train.py
Class Name:
Method Name: main
Project Name: shibing624/pycorrector
Commit Name: a5f63384ac283ea71ca2668963da77db00cafa46
Time: 2019-07-08
Author: 507153809@qq.com
File Name: pycorrector/rnn_lm/infer.py
Class Name:
Method Name: ppl
Project Name: tensorflow/models
Commit Name: c987d27ce7922d08f5d50bf0280b102548fac2a0
Time: 2020-08-15
Author: kaushikshiv@google.com
File Name: research/object_detection/dataset_tools/create_ava_actions_tf_record.py
Class Name: Ava
Method Name: get_label_map