uzh-rpg / sim2real_drone_racing

A Framework for Zero-Shot Sim2Real Drone Racing
http://rpg.ifi.uzh.ch/research_drone_racing.html
MIT License
93 stars 24 forks source link

Can't find the generated data #10

Open Fengaleng opened 4 years ago

Fengaleng commented 4 years ago

Hello there,

I am trying to use your code to generate data for training a CNN of my own. However, I can't seem to do it. Every time I run the collect_python.py file (in the correct directory), the process seems to be running, but i can't find the generated data anywhere. The TRAIN_DIR path leads to a directory that remains empty.

In the command line, other than the error messages caused by the fact that it couldn't open the joystick force feedback, there were these two error messages, and i thought perhaps it was due to them that I can't generate data properly:

[ERROR] [1591312435.843784, 2911.803000]: Spawn service failed. Exiting.

this leads to this red message: [hummingbird/spawn_hummingbird-2] process has died [pid 7162, exit code 1, cmd /opt/ros/melodic/lib/gazebo_ros/spawn_model -param robot_description -urdf -x 0.0 -y 22.0 -z 0.1 -model hummingbird __name:=spawn_hummingbird __log:=/home/fechec/.ros/log/381c0d20-a41b-11ea-972f-080027ba532d/hummingbird-spawn_hummingbird-2.log]. log file: /home/fechec/.ros/log/381c0d20-a41b-11ea-972f-080027ba532d/hummingbird-spawn_hummingbird-2*.log

By looking up the log file, the error seems to come only from the spawn service. Here is what one iteration over the background pictures looks like:

[rospy.client][INFO] 2020-06-04 19:13:52,541: init_node, name[/hummingbird/spawn_hummingbird], pid[7162] [xmlrpc][INFO] 2020-06-04 19:13:52,546: XML-RPC server binding to 0.0.0.0:0 [xmlrpc][INFO] 2020-06-04 19:13:52,546: Started XML-RPC server [http://fechec-VirtualBox:46397/] [rospy.impl.masterslave][INFO] 2020-06-04 19:13:52,546: _ready: http://fechec-VirtualBox:46397/ [xmlrpc][INFO] 2020-06-04 19:13:52,547: xml rpc node: starting XML-RPC server [rospy.init][INFO] 2020-06-04 19:13:52,550: ROS Slave URI: [http://fechec-VirtualBox:46397/] [rospy.registration][INFO] 2020-06-04 19:13:52,550: Registering with master node http://localhost:11311 [rospy.init][INFO] 2020-06-04 19:13:52,651: registered with master [rospy.rosout][INFO] 2020-06-04 19:13:52,651: initializing /rosout core topic [rospy.rosout][INFO] 2020-06-04 19:13:52,663: connected to core topic /rosout [rospy.simtime][INFO] 2020-06-04 19:13:52,667: initializing /clock core topic [rospy.simtime][INFO] 2020-06-04 19:13:52,684: connected to core topic /clock [rosout][INFO] 2020-06-04 19:13:52,698: Loading model XML from ros parameter robot_description [rosout][INFO] 2020-06-04 19:13:52,780: Waiting for service /gazebo/spawn_urdf_model [rospy.internal][INFO] 2020-06-04 19:13:52,937: topic[/rosout] adding connection to [/rosout], count 0 [rospy.internal][INFO] 2020-06-04 19:13:55,492: topic[/clock] adding connection to [http://fechec-VirtualBox:42541/], count 0 [rosout][INFO] 2020-06-04 19:13:55,514: Calling service /gazebo/spawn_urdf_model [rosout][INFO] 2020-06-04 19:13:55,842: Spawn status: SpawnModel: Entity pushed to spawn queue, but spawn service timed out waiting for entity to appear in simulation under the name hummingbird [rosout][ERROR] 2020-06-04 19:13:55,843: Spawn service failed. Exiting. [rospy.core][INFO] 2020-06-04 19:13:55,845: signal_shutdown [atexit] [rospy.internal][INFO] 2020-06-04 19:13:55,847: topic[/rosout] removing connection to /rosout [rospy.internal][INFO] 2020-06-04 19:13:55,850: topic[/clock] removing connection to http://fechec-VirtualBox:42541/ [rospy.impl.masterslave][INFO] 2020-06-04 19:13:55,850: atexit [rospy.internal][WARNING] 2020-06-04 19:13:55,853: Unknown error initiating TCP/IP socket to fechec-VirtualBox:35421 (http://fechec-VirtualBox:42541/): Traceback (most recent call last): File "/opt/ros/melodic/lib/python2.7/dist-packages/rospy/impl/tcpros_base.py", line 563, in connect self.local_endpoint = self.socket.getsockname() AttributeError: 'NoneType' object has no attribute 'getsockname'

If somehow you guys can help me solve this issue, I would greatly appreciate it. I have been looking around for quite a while without finding what was the problem.

Thank you very much!

Feng

P.S. I'm a big fan of you work! It's really cool :)

antonilo commented 4 years ago

The problem might be due to the fact you're using a virtual machine, which is not fully supported for our code. For the training dir path, please set up the path you want the code to save data before starting the data collection process!