msracver / Deformable-ConvNets

Deformable Convolutional Networks
MIT License
4.04k stars 959 forks source link

Error while running python ./rfcn/demo.py on Windows #83

Closed santanpereira closed 7 years ago

santanpereira commented 7 years ago

Can someone help me with resolving below error :

Env Details : Intel Intel Xeon E5-2620 v4 16 Cores 2.10 GHz Up to 2 drives 128 GB, GPU NVIDIA Tesla K80 Graphic Card, OS Windows Server 2016 Standard.

Setup steps :

  1. Install VS C++ build tools 2015
  2. Install VS 2015 Enterprise
  3. Install cuda_8.0.61_win10
  4. Install python 2.7 and install pip with get_pip.py
  5. Install MKL w_mkl_2017.3.210
  6. Download latest prebuildbase_win10_x64_vc14 and 20170901_mxnet_x64_vc14_gpu from https://github.com/yajiedesign/mxnet/releases
  7. Extract and run setupenv.cmd from prebuildbase then replace latest binaries from 20170901_mxnet_x64_vc14_gpu. And then run python setup.py install from /python folder. (This basically sets up all the envs)
  8. Clone https://github.com/msracver/Deformable-ConvNets
  9. pip install Cython pip install opencv-python==3.2.0.6 pip install easydict==1.6
  10. Run init.bat
  11. Try Demo & Deformable Model by downloading and replacing model/ content.
  12. python ./deeplab/demo.py (This Works, on running this got few import error which were resolved by pip install)
  13. python ./rfcn/demo.py (give below error)

Error : C:\Users\Administrator\santan\Deformable-ConvNets>python ./rfcn/demo.py {'CLASS_AGNOSTIC': True, 'MXNET_VERSION': 'mxnet', 'SCALES': [(600, 1000)], 'TEST': {'BATCH_IMAGES': 1, 'CXX_PROPOSAL': False, 'HAS_RPN': True, 'NMS': 0.3, 'PROPOSAL_MIN_SIZE': 0, 'PROPOSAL_NMS_THRESH': 0.7, 'PROPOSAL_POST_NMS_TOP_N': 2000, 'PROPOSAL_PRE_NMS_TOP_N': 20000, 'RPN_MIN_SIZE': 0, 'RPN_NMS_THRESH': 0.7, 'RPN_POST_NMS_TOP_N': 300, 'RPN_PRE_NMS_TOP_N': 6000, 'max_per_image': 100, 'test_epoch': 8}, 'TRAIN': {'ALTERNATE': {'RCNN_BATCH_IMAGES': 0, 'RPN_BATCH_IMAGES': 0, 'rfcn1_epoch': 0, 'rfcn1_lr': 0, 'rfcn1_lr_step': '', 'rfcn2_epoch': 0, 'rfcn2_lr': 0, 'rfcn2_lr_step': '', 'rpn1_epoch': 0, 'rpn1_lr': 0, 'rpn1_lr_step': '', 'rpn2_epoch': 0, 'rpn2_lr': 0, 'rpn2_lr_step': '', 'rpn3_epoch': 0, 'rpn3_lr': 0, 'rpn3_lr_step': ''}, 'ASPECT_GROUPING': True, 'BATCH_IMAGES': 1, 'BATCH_ROIS': -1, 'BATCH_ROIS_OHEM': 128, 'BBOX_MEANS': [0.0, 0.0, 0.0, 0.0], 'BBOX_NORMALIZATION_PRECOMPUTED': True, 'BBOX_REGRESSION_THRESH': 0.5, 'BBOX_STDS': [0.1, 0.1, 0.2, 0.2], 'BBOX_WEIGHTS': array([ 1., 1., 1., 1.]), 'BG_THRESH_HI': 0.5, 'BG_THRESH_LO': 0.0, 'CXX_PROPOSAL': False, 'ENABLE_OHEM': True, 'END2END': True, 'FG_FRACTION': 0.25, 'FG_THRESH': 0.5, 'FLIP': True, 'RESUME': True, 'RPN_BATCH_SIZE': 256, 'RPN_BBOX_WEIGHTS': [1.0, 1.0, 1.0, 1.0], 'RPN_CLOBBER_POSITIVES': False, 'RPN_FG_FRACTION': 0.5, 'RPN_MIN_SIZE': 0, 'RPN_NEGATIVE_OVERLAP': 0.3, 'RPN_NMS_THRESH': 0.7, 'RPN_POSITIVE_OVERLAP': 0.7, 'RPN_POSITIVE_WEIGHT': -1.0, 'RPN_POST_NMS_TOP_N': 300, 'RPN_PRE_NMS_TOP_N': 6000, 'SHUFFLE': True, 'begin_epoch': 5, 'end_epoch': 8, 'lr': 0.0005, 'lr_factor': 0.1, 'lr_step': '5.333', 'model_prefix': 'e2e', 'momentum': 0.9, 'warmup': False, 'warmup_lr': 5e-05, 'warmup_step': 1000, 'wd': 0.0005}, 'dataset': {'NUM_CLASSES': 81, 'dataset': 'coco', 'dataset_path': './data/coco', 'image_set': 'train2014+val2014', 'proposal': 'rpn', 'root_path': './data', 'test_image_set': 'test-dev2015'}, 'default': {'frequent': 20, 'kvstore': 'device'}, 'gpus': '0', 'network': {'ANCHOR_RATIOS': [0.5, 1, 2], 'ANCHOR_SCALES': [4, 8, 16, 32], 'FIXED_PARAMS': ['conv1', 'bn_conv1', 'res2', 'bn2', 'gamma', 'beta'], 'FIXED_PARAMS_SHARED': ['conv1', 'bn_conv1', 'res2', 'bn2', 'res3', 'bn3', 'res4', 'bn4', 'gamma', 'beta'], 'IMAGE_STRIDE': 0, 'NUM_ANCHORS': 12, 'PIXEL_MEANS': array([ 103.06, 115.9 , 123.15]), 'RCNN_FEAT_STRIDE': 16, 'RPN_FEAT_STRIDE': 16, 'pretrained': './model/pretrained_model/resnet_v1_101', 'pretrained_epoch': 0}, 'output_path': './output/rfcn', 'symbol': 'resnet_v1_101_rfcn'} Traceback (most recent call last): File "_ctypes/callbacks.c", line 313, in 'calling callback function' File "C:\Python27\lib\site-packages\mxnet-0.11.1-py2.7.egg\mxnet\operator.py", line 615, in creator kwargs = dict([(py_str(keys[i]), py_str(vals[i])) for i in range(argc)]) ValueError: NULL pointer access Traceback (most recent call last): File "./rfcn/demo.py", line 129, in main() File "./rfcn/demo.py", line 50, in main sym = sym_instance.get_symbol(config, is_train=False) File "C:\Users\Administrator\santan\Deformable-ConvNets\rfcn\symbols\resnet_v1_101_rfcn_dcn.py", line 789, in get_symbol threshold=cfg.TEST.RPN_NMS_THRESH, rpn_min_size=cfg.TEST.RPN_MIN_SIZE) File "", line 23, in Custom File "C:\Python27\lib\site-packages\mxnet-0.11.1-py2.7.egg\mxnet_ctypes\symbol.py", line 127, in _symbol_creator ctypes.byref(sym_handle))) WindowsError: exception: access violation writing 0x0000000000000000

santanpereira commented 7 years ago

Thanks, I was able to resolve all the issues after installing Anaconda2.