reiniscimurs / DRL-robot-navigation

Deep Reinforcement Learning for mobile robot navigation in ROS Gazebo simulator. Using Twin Delayed Deep Deterministic Policy Gradient (TD3) neural network, a robot learns to navigate to a random goal point in a simulated environment while avoiding obstacles.
MIT License
488 stars 98 forks source link

"Updating ModelState" and "RuntimeError: CUDA error: CUBLAS_STATUS_EXECUTION_FAILED" errors #36

Closed KhuongDiep911 closed 1 year ago

KhuongDiep911 commented 1 year ago

I am getting an error saying the "cardboard box does not exist" when I run the command "python3 train_velodyne_td3.py". I still haven't found a solution for it. Please help me!

Screenshot from 2022-11-08 15-44-34

My PC configuration:

Screenshot from 2022-11-08 18-57-07 Screenshot from 2022-11-08 18-57-17 Screenshot from 2022-11-08 18-53-38

reiniscimurs commented 1 year ago

Hi,

The cardboard box error comes from the gazebo simulator as it cannot find the cardboard boxes (described here) in the environment. This probably happens because the correct world file is not being opened. Check that you have sourced everything properly and changed your absolute paths, when running the program. More details on how to do it can be found here. Try opening the gazebo simulator and see if it is opening the right world file.

However, this box error will not cause a crash. Is the program crashing? Can you run it without using cuda as a device?

KhuongDiep911 commented 1 year ago

Hello Reinis Cimurs,

Fortunately, I can fix my problem following your advice about CUDA. Screenshot from 2022-11-09 16-32-54

The first problem is my CUDA, so I uninstalled all my CUDA and pytorch version on my computer. Then I reinstalled it by using two page:

The second problem which is "cardboard doesn't exist" maybe because I clone your repo to my prefer folder. I exported GAZEBO_RESOURCE_PATH to my folder, but it didn't work. Therefore, I decided to clone your repo to my home folder and it works like a charm.

I write it here if someone has the same problem as me.

Thank you very for your advice!

reiniscimurs commented 1 year ago

Great that you managed to get it to work!

Installing in the home directory is probably the easiest way to go to source the repo properly, so that is a very good solution. It could also be done by replacing the absolute paths in source ( in your case I think it would be: export GAZEBO_RESOURCE_PATH=~/tin3080/KHUONG/Project2/repos/DRL-robot-navigation/catkin_ws/src/multi_robot_scenario/launch source ~/.bashrc if I have understood your path to the repo correctly.)

KhuongDiep911 commented 1 year ago

Yeah, that's right. I try to replace the absolute path and it works too.

Thank you!