carla-simulator / carla

Open-source simulator for autonomous driving research.
http://carla.org
MIT License
11.04k stars 3.55k forks source link

Camera frames not showing up #223

Closed eds89 closed 6 years ago

eds89 commented 6 years ago

Hello,

When I load CARLA as a standalone game (non-server), the associated camera frames are not showing up. I can only see them when I launch CARLA as server and connect to it via either Python scripts. It is unclear to me if I should expect seeing the frames for each of the cameras defined in the .ini file.

I'm loading CARLA via the following command line.

CarlaUE4.exe  -carla-settings=CarlaSettings.ini -windowed -ResX=800 -ResY=600

And, my current settings file can be found below. Comments were removed.

[CARLA/Server]
UseNetworking=false
WorldPort=2000
ServerTimeOut=10000
SynchronousMode=true
SendNonPlayerAgentsInfo=false
[CARLA/LevelSettings]
PlayerVehicle=
NumberOfVehicles=90
NumberOfPedestrians=150
WeatherId=1
SeedVehicles=123456789
SeedPedestrians=123456789
[CARLA/SceneCapture]
Cameras=MyCamera
[CARLA/SceneCapture/MyCamera]
PostProcessing=Depth
ImageSizeX=512
ImageSizeY=384
CameraFOV=90
CameraPositionX=15
CameraPositionY=0
CameraPositionZ=123
CameraRotationPitch=8
CameraRotationRoll=0
CameraRotationYaw=0
eds89 commented 6 years ago

Hello, Apparently, the settings file isn't being loaded up, according to the log file:

LogInit: Command line: -windowed -carla-settings=

marcgpuig commented 6 years ago

Hi @eds89,

It is unclear to me if I should expect seeing the frames for each of the cameras defined in the .ini file.

No, you shouldn't. The server does only display the main camera only for debug purposes.

The reason that you see the other cameras in the client side is because it is coded in the manual_control.py to display these frames in that certain position in the screen.

eds89 commented 6 years ago

So, isn't there a way to see what each camera is recording while the car runs through the level?

On 16 February 2018 at 17:55, Marc Garcia Puig notifications@github.com wrote:

Hi @eds89 https://github.com/eds89,

It is unclear to me if I should expect seeing the frames for each of the cameras defined in the .ini file.

No, you shouldn't. The server does only display the main camera only for debug purposes.

The reason that you see the other cameras in the client side is because it is coded in the manual_control.py https://github.com/carla-simulator/carla/blob/master/PythonClient/manual_control.py to display these frames in that certain position in the screen.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/carla-simulator/carla/issues/223#issuecomment-366309926, or mute the thread https://github.com/notifications/unsubscribe-auth/AQUNuVZoC7q3ODQ4WNrS9siU85VCtxMyks5tVcD-gaJpZM4SIpOT .

marcgpuig commented 6 years ago

@eds89,

isn't there a way to see what each camera is recording

If you mean in the server, it is not implemented because this is not a necessary feature for us. Anyway, as it is a post processing material, you can attach it to a certain camera to visualize it.

It's up to you use the Unreal Engine to render different cameras in different frames on a single buffer.

Regards.

eds89 commented 6 years ago

Hello, That's ok. I've managed to change the python code to load settings dynamically (on manual_driving.py). I'm now looking for instructions on how to save recorded images as png files.

On 19 February 2018 at 11:22, Marc Garcia Puig notifications@github.com wrote:

@eds89 https://github.com/eds89,

isn't there a way to see what each camera is recording

If you mean in the server, it is not implemented because this is not a necessary feature for us. Anyway, as it is a post processing material, you can attach it to a certain camera to visualize it.

It's up to you use the Unreal Engine to render different cameras in different frames on a single buffer.

Regards.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/carla-simulator/carla/issues/223#issuecomment-366660955, or mute the thread https://github.com/notifications/unsubscribe-auth/AQUNuageH-znNa9n91xYWuTQm91-Wtw8ks5tWVl7gaJpZM4SIpOT .

marcgpuig commented 6 years ago

Hi @eds89,

Sorry for the late response. Please, make sure you have took a look at the provided python examples before asking.

In the client_example.py you can find an example of saving the images:

https://github.com/carla-simulator/carla/blob/69f7e8ea68046340b1174e8c867381721852b8e1/PythonClient/client_example.py#L104-L107

Good luck :)