-
Notifications
You must be signed in to change notification settings - Fork 35
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
The errors when I did test. #5
Comments
yeah, I find the problem as well. I changed some lines like these in output_drawer.py. It can run normally, but I am not sure how the changes do harms to the results. |
hello, I also have run into this problem when I run test project.Have you solved this problem? please help me. thanks |
@yingning @FantDing @shinjayne Thank you for your attention |
I am having this issue as well. I tried to find a different way of approaching it but it always seems to want an integer. |
I temporary fix the problem this way
This avoid the overflow exception and show textboxes while I try to undestand where is the problem |
The following is code that I used for testing the model after training.
from config import config
from shintb import graph_drawer, default_box_control, svt_data_loader, runner,output_drawer
import tensorflow as tf
flags = tf.app.flags
FLAGS = flags.FLAGS
graphdrawer = graph_drawer.GraphDrawer(config)
dataloader = svt_data_loader.SVTDataLoader('./svt2/train.xml','./svt2/test.xml')
dbcontrol = default_box_control.DefaultBoxControl(config, graphdrawer)
outputdrawer = output_drawer.OutputDrawer(config, dbcontrol)
runner = runner.Runner(config, graphdrawer, dataloader, dbcontrol,outputdrawer)
flags.DEFINE_integer("iter", 10000, "iteration for job")
runner.test(FLAGS.iter)
But I have the following errors:
/home/jsj/shinTB/shintb/utils/box_calculation.py:52: RuntimeWarning: invalid value encountered in double_scalars
right = min(r1[0] + r1[2], r2[0] + r2[2])
/home/jsj/shinTB/shintb/utils/box_calculation.py:53: RuntimeWarning: invalid value encountered in double_scalars
bottom = min(r1[1] + r1[3], r2[1] + r2[3])
PICKED BOXES INFO : [([-inf, 4260720.561588916, inf, 0.044721359549995794], 0.49975014, 0)]
/home/jsj/shinTB/shintb/output_drawer.py:103: RuntimeWarning: invalid value encountered in double_scalars
rect_end = (x+w, y+h)
Traceback (most recent call last):
File "/home/jsj/shinTB/new_file_for_test.py", line 12, in
runner.test(FLAGS.iter)
File "/home/jsj/shinTB/shintb/runner.py", line 196, in test
self.outputdrawer.draw_outputs(test_imgs[0], output_boxes, output_confidence, wait=1)
File "/home/jsj/shinTB/shintb/output_drawer.py", line 104, in draw_outputs
I = cv2.rectangle(I, rect_start, rect_end, (255, 0, 0) , 5 )
TypeError: integer argument expected, got float.
Can you help me fix the problem?
@shinjayne
The text was updated successfully, but these errors were encountered: