where is the source of reshape function in net.blobs['data'].reshape ? (In py-faster-rcnn)

69 views
Skip to first unread message

Chan Kim

unread,
May 31, 2016, 4:22:05 AM5/31/16
to Caffe Users
Hello!
in py-faster-rcnn demo.py code, in def im_detect(net, im boxes=None)  function, I see

    # reshape network inputs Net
    net.blobs['data'].reshape(*(blobs['data'].shape))
    if cfg.TEST.HAS_RPN:
        net.blobs['im_info'].reshape(*(blobs['im_info'].shape))
    else:
        net.blobs['rois'].reshape(*(blobs['rois'].shape))

I now know that the blobs in 'net.blobs' is _Net_blobs function defined in pycaffe.cpp.
(Net.blobs = _Net_blobs at the end of pycaffe.cpp)
The _Net_blobs function returns OrderedDict.

I know class OrderedDict is define din lib/python2.7/collections.py(I'm using anaconda2)
The collections.py doesn't have any definition for reshape.
Then the reshape function is defined where?


Can anybody give me a direction?
Thanks!
Chan


Reply all
Reply to author
Forward
Message has been deleted
0 new messages