Move PythonClient inside deprecated folder
|
@ -1,7 +1,7 @@
|
|||
Build
|
||||
Dist
|
||||
Doxygen
|
||||
PythonClient/dist
|
||||
Deprecated/PythonClient/dist
|
||||
Util/Build
|
||||
Install
|
||||
|
||||
|
|
|
@ -45,10 +45,10 @@ matrix:
|
|||
- python
|
||||
- python-pip
|
||||
install:
|
||||
- pip2 install -q --user -r PythonClient/requirements.txt
|
||||
- pip2 install -q --user -r Deprecated/PythonClient/requirements.txt
|
||||
- pip2 install -q --user pylint
|
||||
script:
|
||||
- pylint --disable=R,C --rcfile=PythonClient/.pylintrc PythonClient/carla PythonClient/*.py
|
||||
- pylint --disable=R,C --rcfile=Deprecated/PythonClient/.pylintrc Deprecated/PythonClient/carla Deprecated/PythonClient/*.py
|
||||
|
||||
- env: TEST="MkDocs"
|
||||
install:
|
||||
|
|
Before Width: | Height: | Size: 534 KiB After Width: | Height: | Size: 534 KiB |
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 27 KiB |
Before Width: | Height: | Size: 33 KiB After Width: | Height: | Size: 33 KiB |
Before Width: | Height: | Size: 175 KiB After Width: | Height: | Size: 175 KiB |
Before Width: | Height: | Size: 400 KiB After Width: | Height: | Size: 400 KiB |
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 15 KiB |
|
@ -131,7 +131,4 @@ If you see a red mark, please correct your code accordingly.
|
|||
- [ ] Your branch is up-to-date with the `master` branch and tested with latest changes
|
||||
- [ ] Extended the README / documentation, if necessary
|
||||
- [ ] Code compiles correctly
|
||||
- [ ] All tests passing
|
||||
- [ ] `make check`
|
||||
- [ ] `pylint --disable=R,C --rcfile=PythonClient/.pylintrc PythonClient/carla PythonClient/*.py`
|
||||
- [ ] `cppcheck . -iBuild -i.pb.cc --enable=warning`
|
||||
- [ ] All tests passing with `make check`
|
||||
|
|
|
@ -213,7 +213,7 @@ vector as we show in the following code excerpt:
|
|||
|
||||
|
||||
|
||||
The full code could be found at [basic_experiment_suite.py](https://github.com/carla-simulator/carla/blob/master/PythonClient/carla/driving_benchmark/experiment_suites/basic_experiment_suite.py)
|
||||
The full code could be found at [basic_experiment_suite.py](https://github.com/carla-simulator/carla/blob/master/Deprecated/PythonClient/carla/driving_benchmark/experiment_suites/basic_experiment_suite.py)
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -1,10 +1,11 @@
|
|||
<h1>Cameras and sensors</h1>
|
||||
|
||||
!!! important
|
||||
This document still refers to the 0.8.X API (stable version). The
|
||||
proceedings stated here may not apply to latest versions, 0.9.0 or later.
|
||||
Latest versions introduced significant changes in the API, we are still
|
||||
working on documenting everything, sorry for the inconvenience.
|
||||
This document still refers to the 0.8.X API (stable version), this API is
|
||||
currently located under _"Deprecated/PythonClient"_. The proceedings stated
|
||||
here may not apply to latest versions, 0.9.0 or later. Latest versions
|
||||
introduced significant changes in the API, we are still working on
|
||||
documenting everything, sorry for the inconvenience.
|
||||
|
||||
!!! important
|
||||
Since version 0.8.0 the positions of the sensors are specified in meters
|
||||
|
@ -30,7 +31,8 @@ moment there are four different sensors available.
|
|||
The images are sent by the server as a BGRA array of bytes. The provided
|
||||
Python client retrieves the images in this format, it's up to the users to
|
||||
parse the images and convert them to the desired format. There are some
|
||||
examples in the PythonClient folder showing how to parse the images.
|
||||
examples in the Deprecated/PythonClient folder showing how to parse the
|
||||
images.
|
||||
|
||||
There is a fourth post-processing effect available for cameras, _None_, which
|
||||
provides a view with of the scene with no effect, not even scene lighting; we
|
||||
|
@ -46,7 +48,7 @@ number_ matches the one received in the measurements. This is especially useful
|
|||
for running the simulator in asynchronous mode and synchronize sensor data on
|
||||
the client side.
|
||||
|
||||
[clientexamplelink]: https://github.com/carla-simulator/carla/blob/master/PythonClient/client_example.py
|
||||
[clientexamplelink]: https://github.com/carla-simulator/carla/blob/master/Deprecated/PythonClient/client_example.py
|
||||
[settingslink]: https://github.com/carla-simulator/carla/blob/master/Docs/Example.CarlaSettings.ini
|
||||
[imgconvlink]: https://github.com/carla-simulator/carla/tree/master/Util/ImageConverter
|
||||
|
||||
|
@ -128,7 +130,7 @@ Our max render distance (far) is 1km.
|
|||
|
||||
The generated "depth map" images are usually converted to a logarithmic
|
||||
grayscale for display. A point cloud can also be extracted from depth images as
|
||||
seen in "PythonClient/point_cloud_example.py".
|
||||
seen in "Deprecated/PythonClient/point_cloud_example.py".
|
||||
|
||||
<h6>Python</h6>
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ CARLA Design
|
|||
CARLA is composed by the following modules
|
||||
|
||||
* Client side
|
||||
- Python client API: "PythonClient/carla"
|
||||
- Python client API: "Deprecated/PythonClient/carla"
|
||||
* Server side
|
||||
- CarlaUE4 Unreal Engine project: "Unreal/CarlaUE4"
|
||||
- Carla plugin for Unreal Engine: "Unreal/CarlaUE4/Plugins/Carla"
|
||||
|
@ -20,7 +20,7 @@ Python client API
|
|||
-----------------
|
||||
|
||||
The client API provides a Python module for communicating with the CARLA server.
|
||||
In the folder "PythonClient", we provide several examples for scripting a CARLA
|
||||
In the folder "Deprecated/PythonClient", we provide several examples for scripting a CARLA
|
||||
client using the "carla" module.
|
||||
|
||||
CarlaUE4 Unreal Engine project
|
||||
|
|
|
@ -8,11 +8,11 @@ aspects of simulation, from environment to duration of each episode, it can
|
|||
retrieve data from different sensors, and send control instructions to the
|
||||
player vehicle.
|
||||
|
||||
PythonClient contents
|
||||
---------------------
|
||||
Deprecated/PythonClient contents
|
||||
--------------------------------
|
||||
|
||||
In the release package, inside the _"PythonClient"_ folder, we provide the
|
||||
Python API module together with some use examples.
|
||||
In the release package, inside the _"Deprecated/PythonClient"_ folder, we
|
||||
provide the Python API module together with some use examples.
|
||||
|
||||
File or folder | Description
|
||||
------------------------ | ------------
|
||||
|
@ -25,9 +25,9 @@ view_start_positions.py | Show all the possible start positions in a map
|
|||
|
||||
!!! note
|
||||
If you are building CARLA from source, the Python code is inside the
|
||||
_"PythonClient"_ folder in the CARLA repository. Bear in mind that the
|
||||
`master` branch contains latest fixes and changes that might be incompatible
|
||||
with the release version. Consider using the `stable` branch.
|
||||
_"Deprecated/PythonClient"_ folder in the CARLA repository. Bear in mind
|
||||
that the `master` branch contains latest fixes and changes that might be
|
||||
incompatible with the release version. Consider using the `stable` branch.
|
||||
|
||||
Install dependencies
|
||||
--------------------
|
||||
|
@ -37,7 +37,7 @@ given examples is also compatible with Python 2.7.
|
|||
|
||||
Install the dependencies with "pip" using the requirements file provided
|
||||
|
||||
$ pip install -r PythonClient/requirements.txt
|
||||
$ pip install -r Deprecated/PythonClient/requirements.txt
|
||||
|
||||
Running the client example
|
||||
--------------------------
|
||||
|
@ -96,7 +96,6 @@ You can see all the available options in the script's help
|
|||
|
||||
<h4>Running other examples</h4>
|
||||
|
||||
The other scripts present in the _"PythonClient"_ folder run in a similar
|
||||
fashion. We recommend now launching _"manual_control.py"_ for a GUI interface
|
||||
implemented with PyGame.
|
||||
|
||||
The other scripts present in the _"Deprecated/PythonClient"_ folder run in a
|
||||
similar fashion. We recommend now launching _"manual_control.py"_ for a GUI
|
||||
interface implemented with PyGame.
|
||||
|
|
|
@ -8,10 +8,7 @@ Checklist:
|
|||
- [ ] Your branch is up-to-date with the `master` branch and tested with latest changes
|
||||
- [ ] Extended the README / documentation, if necessary
|
||||
- [ ] Code compiles correctly
|
||||
- [ ] All tests passing
|
||||
- [ ] `make check`
|
||||
- [ ] `pylint --disable=R,C --rcfile=PythonClient/.pylintrc PythonClient/carla PythonClient/*.py`
|
||||
- [ ] `cppcheck . -iBuild -i.pb.cc --enable=warning`
|
||||
- [ ] All tests passing with `make check`
|
||||
|
||||
-->
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
set PROTOBUF_SRC_DIR=Proto
|
||||
set PROTOBUF_CPP_OUT_DIR=CarlaServer/source/carla/server
|
||||
set PROTOBUF_PY_OUT_DIR=../PythonClient/carla
|
||||
set PROTOBUF_PY_OUT_DIR=../Deprecated/PythonClient/carla
|
||||
set PROTO_BASENAME=carla_server
|
||||
|
||||
if "%1" == "--clean" (
|
||||
|
|
|
@ -7,7 +7,7 @@ pushd "$SCRIPT_DIR" >/dev/null
|
|||
|
||||
PROTOBUF_SRC_DIR=Proto
|
||||
PROTOBUF_CPP_OUT_DIR=CarlaServer/source/carla/server
|
||||
PROTOBUF_PY_OUT_DIR=../PythonClient/carla
|
||||
PROTOBUF_PY_OUT_DIR=../Deprecated/PythonClient/carla
|
||||
PROTO_BASENAME=carla_server
|
||||
|
||||
if [ "$1" == "--clean" ]; then
|
||||
|
|
|
@ -16,7 +16,7 @@ This ros package aims at providing a simple ros bridge for carla simulator.
|
|||
- [x] Lidar sensor support
|
||||
- [x] Transform publications
|
||||
- [x] Manual control using ackermann msg
|
||||
- [x] Autopilot mode using rosparam
|
||||
- [x] Autopilot mode using rosparam
|
||||
- [x] Rosbag in the bridge (in order to avoid rosbag recoard -a small time errors)
|
||||
- [x] Handle ros dependencies
|
||||
- [x] Marker/bounding box messages for cars/pedestrian
|
||||
|
@ -33,21 +33,21 @@ This ros package aims at providing a simple ros bridge for carla simulator.
|
|||
mkdir -p ~/ros/catkin_ws_for_carla/src
|
||||
cd ~/ros/catkin_ws_for_carla
|
||||
source /opt/ros/kinetic/setup.bash
|
||||
catkin_make
|
||||
catkin_make
|
||||
source ~/ros/catkin_ws_for_carla/devel/setup.bash
|
||||
|
||||
For more information about configuring a ros environment see
|
||||
|
||||
For more information about configuring a ros environment see
|
||||
http://wiki.ros.org/ROS/Tutorials/InstallingandConfiguringROSEnvironment
|
||||
|
||||
## Install carla python client in your workspace
|
||||
|
||||
cd carla/PythonClient
|
||||
pip2 install -e . --user --upgrade
|
||||
|
||||
cd carla/Deprecated/PythonClient
|
||||
pip2 install -e . --user --upgrade
|
||||
|
||||
Check the installation is successfull by trying to import carla from python:
|
||||
|
||||
python -c 'import carla;print("Success")'
|
||||
|
||||
|
||||
You should see the Success message without any errors.
|
||||
|
||||
### Install recent protobuf version [optional]
|
||||
|
@ -55,9 +55,9 @@ You should see the Success message without any errors.
|
|||
sudo apt-get remove python-protobuf
|
||||
sudo pip2 install --upgrade protobuf
|
||||
|
||||
|
||||
|
||||
### Add the carla_ros_bridge in the catkin workspace
|
||||
|
||||
|
||||
Run the following command after replacing [PATH_TO_CARLA] with the actual path to carla directory on your machine:
|
||||
|
||||
ln -s [PATH_TO_CARLA]/carla_ros_bridge/ ~/ros/catkin_ws_for_carla/src/
|
||||
|
@ -67,23 +67,23 @@ Run the following command after replacing [PATH_TO_CARLA] with the actual path t
|
|||
cd ~/ros/catkin_ws_for_carla
|
||||
catkin_make
|
||||
source ~/ros/catkin_ws_for_carla/devel/setup.bash
|
||||
|
||||
|
||||
|
||||
### Test your installation
|
||||
|
||||
|
||||
If you use the builded binary (0.8.2):
|
||||
|
||||
./CarlaUE4.sh -carla-server -windowed -ResX=320 -ResY=240
|
||||
|
||||
|
||||
|
||||
Wait for the message:
|
||||
|
||||
Waiting for the client to connect...
|
||||
|
||||
|
||||
Then run the tests
|
||||
|
||||
|
||||
rostest carla_ros_bridge ros_bridge_client.test
|
||||
|
||||
|
||||
you should see:
|
||||
|
||||
[carla_ros_bridge.rosunit-testTopics/test_publish][passed]
|
||||
|
@ -92,7 +92,7 @@ you should see:
|
|||
* RESULT: SUCCESS
|
||||
|
||||
|
||||
|
||||
|
||||
# Start the ros bridge
|
||||
|
||||
First run the simulator (see carla documentation: http://carla.readthedocs.io/en/latest/)
|
||||
|
@ -108,11 +108,11 @@ Then start the ros bridge:
|
|||
|
||||
source ~/ros/catkin_ws_for_carla/devel/setup.bash
|
||||
roslaunch carla_ros_bridge client.launch
|
||||
|
||||
|
||||
To start the ros bridge with rviz use:
|
||||
|
||||
roslaunch carla_ros_bridge client_with_rviz.launch
|
||||
|
||||
|
||||
You can setup the wanted camera/sensors in config/settings.yaml.
|
||||
|
||||
# Autopilot control
|
||||
|
@ -120,13 +120,13 @@ You can setup the wanted camera/sensors in config/settings.yaml.
|
|||
To enable autopilot control set the ros param carla_autopilot to True
|
||||
|
||||
rosparam set carla_autopilot True
|
||||
|
||||
# Manual control
|
||||
|
||||
# Manual control
|
||||
|
||||
To enable manual control set the ros param carla_autopilot to False
|
||||
|
||||
rosparam set carla_autopilot False
|
||||
|
||||
|
||||
|
||||
Then you can send command to the car using the /ackermann_cmd topic.
|
||||
|
||||
|
@ -134,16 +134,16 @@ Example of forward movements, speed in in meters/sec.
|
|||
|
||||
rostopic pub /ackermann_cmd ackermann_msgs/AckermannDrive "{steering_angle: 0.0, steering_angle_velocity: 0.0, speed: 10, acceleration: 0.0,
|
||||
jerk: 0.0}" -r 10
|
||||
|
||||
|
||||
|
||||
|
||||
Example of forward with steering
|
||||
|
||||
|
||||
rostopic pub /ackermann_cmd ackermann_msgs/AckermannDrive "{steering_angle: 5.41, steering_angle_velocity: 0.0, speed: 10, acceleration: 0.0,
|
||||
jerk: 0.0}" -r 10
|
||||
|
||||
|
||||
Warning: the steering_angle is the driving angle (in radians) not the wheel angle, for now max wheel is set to 500 degrees.
|
||||
|
||||
|
||||
|
||||
|
||||
Example for backward :
|
||||
|
||||
rostopic pub /ackermann_cmd ackermann_msgs/AckermannDrive "{steering_angle: 0, steering_angle_velocity: 0.0, speed: -10, acceleration: 0.0,
|
||||
|
|