Wiki | Community | Discussion Forum | Q&A

Problems with the follow-line environment

Hello!

I’m having trouble launching the “follow line” exercise code.

During the installation “General Infrastructure” did not give me any error, in addition, I have installed the openCV package in python 2 and python 3 so there are no version problems.

I launch the command “roslaunch” and gazebo opens with the world of formula 1 track without any problem, however I run the code with the commands “python follow_line.py follow_line_conf.yml” or "python2 ./follow_line.py follow_line_conf.yml "and the car does nothing.

I have tried a simple test code “self.motors.sendV (10)” and if it moves, but creating the mask and trying to display it doesn’t.

I have passed my MyAlgorithm.py file to a partner and it runs perfectly.

I have reinstalled the entire Robotics-Academy environment and cannot solve the problem.

Thank you,
Garazi.

Hello!

From what I get, you are saying that the simple test code works. But, the code along with displaying the mask does not work. Correct me if I am wrong.

How are you displaying the mask? Is it using an opencv function or using the interface api. Can you share its code snippet?

With the help of my classmates I have solved it. It was a lighting problem, I was not detecting the red line of the road correctly and I was not filtering correctly.
I have solved it by placing a “directional light”, with the following configuration, which has been proposed by a companion of the master.

Anyway thank you very much.

Cheers!