Closed fujimo-t closed 4 years ago
My environment is Melodic and it seems that fix is needed for other distro.
Kinetic and Melodic are OK but Indigo is not.
Currently dis_flow nodelet is not built on Indigo by the CMakeLists.txt. But test and launch file of dis_flow are installed on Indigo and they cause an error of launch file check. Also nodelet_plugins.xml shouldn't include dis_flow on Indigo.
I think split branch Indigo and Kinetic or later is easiest way. But should I not split branch for only a nodelet?
we already have similar problem on other optical flow algorithm, please look at https://github.com/ros-perception/opencv_apps/blob/indigo/CMakeLists.txt#L9-L11
Same error will happen if the condition of simple flow is false.
if(OpenCV_VERSION VERSION_LESS "3.0" OR TARGET opencv_optflow)
But the condition is always true if we use normal ROS environment, so actually there is no problem in simple flow's case.
I will try to exclude files related to dis_flow from install files if OpenCV version is not enough.
Now launch and test files of dis flow is not installed and test is not done, if dis flow is not available.
Travis is failed on OPENCV_VERSION=2 ROS_DISTRO=indigo DOCKER_IMAGE=ubuntu:trusty
but it seems an issue unrelated to this PR.
At https://travis-ci.org/ros-perception/opencv_apps/jobs/513244849#L4949
[ROSTEST]-----------------------------------------------------------------------
[opencv_apps.rosunit-lk_flow_test/test_hz][FAILURE]-----------------------------
average rate (0.873Hz) exceeded minimum (1.000Hz)
File "/usr/lib/python2.7/unittest/case.py", line 331, in run
testMethod()
File "/opt/ros/indigo/share/rostest/nodes/hztest/hztest", line 117, in test_hz
self._test_hz(hz, hzerror, topic, test_duration, wait_time)
File "/opt/ros/indigo/share/rostest/nodes/hztest/hztest", line 187, in _test_hz
(rate, self.min_rate))
File "/usr/lib/python2.7/unittest/case.py", line 424, in assertTrue
raise self.failureException(msg)
--------------------------------------------------------------------------------
SUMMARY
* RESULT: FAIL
* TESTS: 1
* ERRORS: 0
* FAILURES: 1
Closed because I'm busy now and can't update PR.
This is Nodelet for OpenCV implementation of DIS optical flow. The nodelet can be built on only Kinetic or Melodic because DIS Flow has appeared in opencv_contrib since OpenCV 3.2.
This is based on sample of DIS Flow in OpenCV 4.0