Creating .world file. World did not load with custom world name

asked 2017-12-13 06:48:57 -0600

elcymon gravatar image

I am trying to create a world using the sdf format.

In the tutorials, the world tag has a name attribute for the unique world name.

The example says to name the world as

<world name='default'>

However, I want the name for my world to be different from 'default'. So I did this:

<world name='my_world'>

I realized that the world did not load with my custom world name.

It only runs when the name attribute is 'default'.

Is this the expected behaviour?

Many thanks

edit retag flag offensive close merge delete


Could you provide a minimal example that reproduces your issue? Custom names work fine for me.

chapulina gravatar imagechapulina ( 2017-12-13 10:03:13 -0600 )edit

Also, what Gazebo version are you using?

chapulina gravatar imagechapulina ( 2017-12-13 10:03:58 -0600 )edit

I am using Gazebo 7.4 I tried a simple world example and it works with custom world name. The problem seems to come when the number of models in the world are large. I populate my world with about 200 red boxes. The world didn't load when I used custom world name after waiting for minutes. However, it loaded within seconds when I used "default". upon reducing the number of red boxes model to about 30, the world loaded with custom world names. Is there any logical explanation for this?

elcymon gravatar imageelcymon ( 2017-12-14 03:04:27 -0600 )edit

Sounds like it could be this issue: After the world is loaded, if you do `gz topic -l`, does it show some topics with the custom name and others with default?

chapulina gravatar imagechapulina ( 2017-12-14 11:14:31 -0600 )edit

Yes it does show the topics with custom world name.

elcymon gravatar imageelcymon ( 2017-12-14 11:29:28 -0600 )edit

Wait, all the topics have the custom name, or do some of them show default?

chapulina gravatar imagechapulina ( 2017-12-14 12:20:18 -0600 )edit

You are right @chapulina. Some topics use the "custom world name" while others use "default"

elcymon gravatar imageelcymon ( 2017-12-15 02:41:07 -0600 )edit

Ahh then that's the issue mentioned above. Unfortunately I don't think there is a fix yet, besides using the default world name.

chapulina gravatar imagechapulina ( 2017-12-15 13:43:46 -0600 )edit