diff --git a/paddlex/cv/models/utils/pretrain_weights.py b/paddlex/cv/models/utils/pretrain_weights.py index 3684def9fee7af6b9b3d809ee0a622673c76838a..3abbdd93d80efd5eb41ead32ac321d758d080104 100644 --- a/paddlex/cv/models/utils/pretrain_weights.py +++ b/paddlex/cv/models/utils/pretrain_weights.py @@ -99,11 +99,10 @@ def get_pretrain_weights(flag, model_type, backbone, save_dir): backbone = 'DetResNet50' assert backbone in image_pretrain, "There is not ImageNet pretrain weights for {}, you may try COCO.".format( backbone) - if backbone.startswith("HRNet"): - url = image_pretrain[backbone] - fname = osp.split(url)[-1].split('.')[0] - paddlex.utils.download_and_decompress(url, path=new_save_dir) - return osp.join(new_save_dir, fname) + # url = image_pretrain[backbone] + # fname = osp.split(url)[-1].split('.')[0] + # paddlex.utils.download_and_decompress(url, path=new_save_dir) + # return osp.join(new_save_dir, fname) try: hub.download(backbone, save_path=new_save_dir) except Exception as e: