tianzhi0549 / FCOS

FCOS: Fully Convolutional One-Stage Object Detection (ICCV'19)
https://arxiv.org/abs/1904.01355
Other
3.28k stars 630 forks source link

TypeError: __init__() got an unexpected keyword argument 'confidence_threshold' #91

Open hugonbgg opened 5 years ago

hugonbgg commented 5 years ago

I can successfully run fcos_demo.py I can successfully run fcos_demo.py, but when I try to run webcam.py, I get the error:

Traceback (most recent call last):    File "webcam.py", line 80, in      main ()    File "webcam.py", line 64, in main      min_image_size = args.min_image_size, TypeError: init () got an unexpected keyword argument 'confidence_threshold'

The same error occours in Mask_R-CNN_demo.ipynb.

I am using : Windows 10 Python 3.7 pytorch 1.1.0 py3.7_cuda100_cudnn7_1 pytorch torchvision 0.3.0 py37_cu100_1 pytorch

tianzhi0549 commented 5 years ago

@hugonbg Sorry about that. webcam.py is not modified for this project. If you want to use it, please modify it accordingly.

MsRabbits commented 5 years ago

I can successfully run fcos_demo.py I can successfully run fcos_demo.py, but when I try to run webcam.py, I get the error:

Traceback (most recent call last):    File "webcam.py", line 80, in      main ()    File "webcam.py", line 64, in main      min_image_size = args.min_image_size, TypeError: init () got an unexpected keyword argument 'confidence_threshold'

The same error occours in Mask_R-CNN_demo.ipynb.

I am using : Windows 10 Python 3.7 pytorch 1.1.0 py3.7_cuda100_cudnn7_1 pytorch torchvision 0.3.0 py37_cu100_1 pytorch

hello,did u successfully run the demo on win10?could you give me some advice about the error after i run the demo.py:

(tree) F:\somecoders\FCOS-master>python demo/fcos_demo.py Traceback (most recent call last): File "demo/fcos_demo.py", line 109, in main() File "demo/fcos_demo.py", line 93, in main min_image_size=args.min_imagesize File "f:\somecoders\fcos-master\demo\predictor.py", line 117, in init = checkpointer.load(cfg.MODEL.WEIGHT) File "f:\somecoders\fcos-master\fcos_core\utils\checkpoint.py", line 61, in load checkpoint = self._load_file(f) File "f:\somecoders\fcos-master\fcos_core\utils\checkpoint.py", line 136, in _load_file loaded = super(DetectronCheckpointer, self)._load_file(f) File "f:\somecoders\fcos-master\fcos_core\utils\checkpoint.py", line 95, in _load_file return torch.load(f, map_location=torch.device("cpu")) File "E:\anaconda\anaconda\envs\tree\lib\site-packages\torch\serialization.py", line 366, in load f = open(f, 'rb') FileNotFoundError: [Errno 2] No such file or directory: 'FCOS_imprv_R_50_FPN_1x.pth'