Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix index bug.the original index is a float datatype #69

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

fix index bug.the original index is a float datatype #69

wants to merge 1 commit into from

Conversation

elias-1
Copy link

@elias-1 elias-1 commented Jan 25, 2017

The error info is presented as follows:

Traceback (most recent call last): File "/home/elias/code/tensorflow-env-0-11/local/lib/python2.7/site-packages/tensorflow/python/ops/script_ops.py", line 83, in __call__ ret = func(*args) File "/home/elias/code/Faster-RCNN_TF/tools/../lib/rpn_msr/proposal_target_layer_tf.py", line 48, in proposal_target_layer rois_per_image, _num_classes) File "/home/elias/code/Faster-RCNN_TF/tools/../lib/rpn_msr/proposal_target_layer_tf.py", line 154, in _sample_rois _get_bbox_regression_labels(bbox_target_data, num_classes) File "/home/elias/code/Faster-RCNN_TF/tools/../lib/rpn_msr/proposal_target_layer_tf.py", line 90, in _get_bbox_regression_labels bbox_targets[ind, start:end] = bbox_target_data[ind, 1:] TypeError: slice indices must be integers or None or have an __index__ method
Traceback (most recent call last): File "/home/elias/code/tensorflow-env-0-11/local/lib/python2.7/site-packages/tensorflow/python/ops/script_ops.py", line 83, in __call__ ret = func(*args) File "/home/elias/code/Faster-RCNN_TF/tools/../lib/rpn_msr/proposal_target_layer_tf.py", line 48, in proposal_target_layer rois_per_image, _num_classes) File "/home/elias/code/Faster-RCNN_TF/tools/../lib/rpn_msr/proposal_target_layer_tf.py", line 139, in _sample_rois bg_inds = npr.choice(bg_inds, size=bg_rois_per_this_image, replace=False) File "mtrand.pyx", line 1176, in mtrand.RandomState.choice (numpy/random/mtrand/mtrand.c:18822) TypeError: 'numpy.float64' object cannot be interpreted as an index

wadefelix pushed a commit to wadefelix/Faster-RCNN_TF that referenced this pull request Feb 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant