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

Error when calling create_source with OpenNISubscriber as 2nd argument #7

Closed
corot opened this issue Mar 15, 2015 · 4 comments
Closed
Assignees
Milestone

Comments

@corot
Copy link

corot commented Mar 15, 2015

Hi, not sure if this is an issue at all, or I'm just trying to over abuse camera_base. Feel free to close this if so!

I'm trying to run object_recognition_capture orb_template with a non OpenNI camera (see this post on ORK group), so I pass OpenNISubscriber to create_source instead of OpenNISource (and also remove the mask_depth from the outputs_list). But I get an error complaining that this is not a ROS node:

$ rosrun object_recognition_capture orb_template -o my_textured_plane
INIT
Listening for key: s on imshow:save
[FATAL] [1426455554.600357664]: You must call ros::init() before creating the first NodeHandle
Couldn't find an AF_INET address for []
Couldn't find an AF_INET address for []
[ERROR] [1426455554.601597709]: [registerPublisher] Failed to contact master at [:0].  Retrying...
Couldn't find an AF_INET address for []
Couldn't find an AF_INET address for []
......

I crudely tried to call rospy.init_node but changes nothing. So it's really a missing ros::init() in a C++ ecto cell?
Please note that I'm trying to use ORK in an undocumented way, so... it's probably that I'm just trying something stupid without understanding the ecto_image_pipeline.

@stonier
Copy link

stonier commented Mar 15, 2015

Did you call something like:

ecto_ros.init(sys.argv, "my_node_name", anonymous=False)

from somewhere in your python script? This initialises the underlying c++ node.

@corot
Copy link
Author

corot commented Mar 15, 2015

right. danke!

Still doesn't work but now is opencv complaining about some incompatibilities between images. Maybe there's something weird on the creation of the cv::Mat, or maybe is some exotic property on Senz3D generated images.

OpenCV Error: Assertion failed (0 <= _rowRange.start && _rowRange.start <= _rowRange.end && _rowRange.end <= m.rows) in Mat, file /build/buildd/opencv-2.4.8+dfsg1/modules/core/src/matrix.cpp, line 284
Traceback (most recent call last):
  File "/opt/ros/indigo/lib/object_recognition_capture/orb_template", line 115, in <module>
    run_plasm(options, plasm, locals=vars())
  File "/opt/ros/indigo/lib/python2.7/dist-packages/ecto/opts.py", line 85, in run_plasm
    sched.execute(options.niter)
ecto.CellException:            exception_type  CellException
[cell_name] = Source

[cell_type] = ecto::py::BlackBox

[function_name] = process_with_only_these_inputs

[type] = std::runtime_error

[what] =            exception_type  CellException
[cell_name] = RescaledRegisteredDepth

[cell_type] = RescaledRegisteredDepth

[function_name] = process_with_only_these_inputs

[type] = cv::Exception

[what] = /build/buildd/opencv-2.4.8+dfsg1/modules/core/src/matrix.cpp:284: error: (-215) 0 <= _rowRange.start && _rowRange.start <= _rowRange.end && _rowRange.end <= m.rows in function Mat

@corot corot closed this as completed Mar 15, 2015
@stonier
Copy link

stonier commented Mar 15, 2015

You could be running into the same problem on ecto 0.6.8 as being hunted in plasmodic/ecto#272. As it is there, suspicious that you're dropping into process_with_only_these_inputs.

Get the ecto sources and checkout the 0.6.7 tag to make sure.

@stonier stonier added this to the Indigo milestone Mar 15, 2015
@stonier stonier self-assigned this Mar 15, 2015
@corot
Copy link
Author

corot commented Mar 16, 2015

mmm.... don't think so, as it works for the images provided by kinect (well... actually, it also fails but something different and later.
I'll try ecto sources, anyway. Thanks!

confirmed : it also fails with 0.6.7 tag. Must be an issue with the Senz3D BGR format. Maybe it's just too big! (the resolution is 720x1280)

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

No branches or pull requests

2 participants