awesome-semantic-segmentation-pytorch icon indicating copy to clipboard operation
awesome-semantic-segmentation-pytorch copied to clipboard

please help me! ValueError: Model file is not found. Downloading or trainning.

Open electronicYH opened this issue 4 years ago • 4 comments

amax@amax:/data/yh/awesome-semantic-segmentation-pytorch/scripts$ ./dfanet_resnet18_pascal_voc.sh /home/amax/anaconda3/lib/python3.6/site-packages/requests/init.py:80: RequestsDependencyWarning: urllib3 (1.25.3) or chardet (3.0.4) doesn't match a supported version! RequestsDependencyWarning) 2019-08-21 14:15:23,071 semantic_segmentation INFO: Using 1 GPUs 2019-08-21 14:15:23,071 semantic_segmentation INFO: Namespace(aux=False, aux_weight=0.4, backbone='resnet18', base_size=520, batch_size=4, crop_size=480, dataset='pascal_voc', device='cuda', distributed=False, epochs=80, jpu=False, local_rank=0, log_dir='../runs/logs/', log_iter=10, lr=0.0001, model='dfanet', momentum=0.9, no_cuda=False, num_gpus=1, resume=None, save_dir='~/.torch/models', save_epoch=10, skip_val=False, start_epoch=0, use_ohem=False, val_epoch=1, warmup_factor=0.3333333333333333, warmup_iters=0, warmup_method='linear', weight_decay=0.0001, workers=4) Found 14752 images in the folder ../datasets/voc/VOC2019 Found 388 images in the folder ../datasets/voc/VOC2019 Traceback (most recent call last): File "train.py", line 326, in trainer = Trainer(args) File "train.py", line 162, in init aux=args.aux, jpu=args.jpu, norm_layer=BatchNorm2d).to(self.device) File "/data/yh/awesome-semantic-segmentation-pytorch/core/models/model_zoo.py", line 122, in get_segmentation_model return modelsmodel File "/data/yh/awesome-semantic-segmentation-pytorch/core/models/dfanet.py", line 97, in get_dfanet model = DFANet(datasets[dataset].NUM_CLASS, backbone=backbone, pretrained_base=pretrained_base, **kwargs) File "/data/yh/awesome-semantic-segmentation-pytorch/core/models/dfanet.py", line 15, in init self.pretrained = get_xception_a(pretrained_base, **kwargs) File "/data/yh/awesome-semantic-segmentation-pytorch/core/models/base_models/xception.py", line 406, in get_xception_a model.load_state_dict(torch.load(get_model_file('xception_a', root=root))) File "/data/yh/awesome-semantic-segmentation-pytorch/core/models/model_store.py", line 68, in get_model_file raise ValueError('Model file is not found. Downloading or trainning.') ValueError: Model file is not found. Downloading or trainning.

electronicYH avatar Aug 21 '19 06:08 electronicYH

Pleae change the path to your model path.

Tramac avatar Sep 24 '19 05:09 Tramac

@Tramac Hi,thanks for your work, I wonder how could I get the pre-trained weights of backbone network Xception_A for training DFANet? I check the model_store and not find any url or link for it.

wangq95 avatar Mar 22 '20 02:03 wangq95

@wangq95 Hi, did you get the pre-trained weights of backbone network Xception_A?

qifenpibei avatar Sep 17 '20 13:09 qifenpibei

set pre-trained is False

xiayouran avatar Dec 30 '21 07:12 xiayouran