facebookresearch / Detectron

FAIR's research platform for object detection research, implementing popular algorithms like Mask R-CNN and RetinaNet.
Apache License 2.0
26.21k stars 5.45k forks source link

yaml.constructor.ConstructorError: from cfg.merge_from_file #992

Open Naveen03 opened 4 years ago

Naveen03 commented 4 years ago

I am running on CPU, while merging confg from yaml file I am getting below error. tried many blogs but was not able to resolve it. I was trying object detection using COCO-Detection/retinanet_R_101_FPN_3x

Here is full error "yaml.constructor.ConstructorError: could not determine a constructor for the tag 'tag:yaml.org,2002:python/object/apply:eval' in "/home/ubuntu/.local/lib/python3.6/site-packages/detectron2/model_zoo/configs/COCO-Detection/../Base-RetinaNet.yaml", line 8, column 12"

and follows another error "cfg = yaml.unsafe_load(f) # pyre-ignore AttributeError: module 'yaml' has no attribute 'unsafe_load"

Please provide me any leads Thank you

hcyz33 commented 4 years ago

I encountered a similar problem.

Here is full error yaml.constructor.ConstructorError: could not determine a constructor for the tag 'tag:yaml.org,2002:python/object/apply:numpy.core.multiarray.scalar' in "", line 3, column 20: BBOX_XFORM_CLIP: !!python/object/apply:numpy.core ... If you have solved it, please help me

Naveen03 commented 4 years ago

Update your yaml parser.

On Sat, Jun 6, 2020, 1:11 PM hcyz33 notifications@github.com wrote:

I encountered a similar problem.

Here is full error yaml.constructor.ConstructorError: could not determine a constructor for the tag 'tag:yaml.org ,2002:python/object/apply:numpy.core.multiarray.scalar' in "", line 3, column 20: BBOX_XFORM_CLIP: !!python/object/apply:numpy.core ... If you have solved it, please help me

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/facebookresearch/Detectron/issues/992#issuecomment-640005517, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACZZZJY42OA3MIJCNDTGLH3RVHXLHANCNFSM4MX2OXGQ .