CasonTsai / MaskRcnn_tensorflow_cpp_inference

inference mask_rcnn model with tensorflow c++ api
MIT License
46 stars 10 forks source link

run error #4

Open liyun2017 opened 4 years ago

liyun2017 commented 4 years ago

Hello, I learned a lot from you. After configuring C ++, run your code main.cpp on Windows (without any changes), but the following error occurred:
when i run : detectBatchTmp.initConfig(detect_size_w, detect_size_h) -> get_anchors() -> inputAnchorsTensor_temp.chip(i,1)=eachrow

If an error occurs, debug is broken, and it appears in the following code.

EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE bool evalSubExprsIfNeeded(Scalar*) { eigen_assert(dimensions_match(m_leftImpl.dimensions(), m_rightImpl.dimensions())); m_leftImpl.evalSubExprsIfNeeded(NULL); // If the lhs provides raw access to its storage area (i.e. if m_leftImpl.data() returns a non // null value), attempt to evaluate the rhs expression in place. Returns true iff in place // evaluation isn't supported and the caller still needs to manually assign the values generated // by the rhs to the lhs. return m_rightImpl.evalSubExprsIfNeeded(m_leftImpl.data()); }

I'm not familiar with eigen, I can't understand how the code works. Thank you for giving me some suggestions.

CasonTsai commented 4 years ago

in this project ,you should make the detect_size_w,detect_size_h be same with the input of the maskrcnn network,e.g ,if you train the network with input of 512*512,you should keep the detect_size_w ,detect_size_h =512,,