From 36c9a6bdae33d3ef5e38620441efa736b1c93049 Mon Sep 17 00:00:00 2001 From: Max Spahn Date: Wed, 2 Mar 2022 17:26:34 +0100 Subject: [PATCH] Adds explicit short getting started to docs, addresses #4. --- docs/source/example.rst | 2 + docs/source/getting_started.rst | 96 +++++++++++++++++++++++++++++++++ docs/source/index.rst | 1 + docs/source/introduction.rst | 75 -------------------------- 4 files changed, 99 insertions(+), 75 deletions(-) create mode 100644 docs/source/getting_started.rst diff --git a/docs/source/example.rst b/docs/source/example.rst index 0604fc3..db99d33 100644 --- a/docs/source/example.rst +++ b/docs/source/example.rst @@ -1,3 +1,5 @@ +.. _example_long: + Example ================== diff --git a/docs/source/getting_started.rst b/docs/source/getting_started.rst new file mode 100644 index 0000000..4b0d1f4 --- /dev/null +++ b/docs/source/getting_started.rst @@ -0,0 +1,96 @@ +Getting started +===================================== + +This is the guide to quickly get going with the local motion planning benchmark suite. + + +Pre-requisites +----------------- + +- Linux Ubuntu LTS >= 18.04 +- Python >3.6, < 3.10 +- pip3 +- gnuplot (``sudo apt install gnuplot``) +- [Optional] `poetry `_ +- [Optional] `embotech forces pro `_ for mpc + + +Installation +------------ + +You first have to download the repository + +.. code:: bash + + git clone git@github.com:maxspahn/localPlannerBench.git + +Then, you can install the package using pip as: + +.. code:: bash + + pip3 install . + +Optional: Installation with poetry +------------------------------------ + +If you want to use `poetry `_, you have +to install it first. See their webpage for instructions +`docs `_. Once poetry is installed, you can +install the virtual environment with the following commands. Note that during +the first installation ``poetry update`` takes up to 300 secs. + +.. code:: bash + + poetry update + poetry install + +The virtual environment is entered by + +.. code:: bash + + poetry shell + +Tutorial +------------ + +The following is a very simple example case. + +Run an experiments: + +Experiments should be added in separate folder in ``experiments``. +One very simple example can be found in this folder. +Note that you need to active your poetry shell if you have installed the package using +poetry by + +.. code:: bash + + poetry shell + +Then you navigate there by + +.. code:: bash + + cd experiments/1_fabric_mpc/pointMass + +Then the experiment is run with the command line interface + +.. code:: bash + + ../../../plannerbenchmark/exec/runner -c setup/exp.yaml -p fabric setup/fabric.yaml --render + +Postprocessing: + +The experiments can be postprocessed using the provide executable. When +using poetry, make sure you are in the virtual environment (``poetry shell``) + +.. code:: bash + + cd path/to/folder/of/experiment + +The you can run the post processor with arguments as + +.. code:: bash + + ../../../plannerbenchmark/exec/postProcessor --exp path/to/experiment -k time2Goal pathLength --plot + +More detailed information about this example can be found in :ref:`example_long` diff --git a/docs/source/index.rst b/docs/source/index.rst index 1a64169..d21de08 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -11,6 +11,7 @@ Welcome to Local Planner Bench's documentation! :caption: Contents: introduction + getting_started example structure diff --git a/docs/source/introduction.rst b/docs/source/introduction.rst index 6f7fb08..e921c90 100644 --- a/docs/source/introduction.rst +++ b/docs/source/introduction.rst @@ -6,78 +6,3 @@ local motion planning algorithms. Running and postprocessing is available and we aim to offer a nice interface to implement a wrapper to your own motion planner. -Dependencies -------------- - -The package generates plots using `gnuplot`. Gnuplot can be installed on ubuntu -using aptitude. - -.. code:: bash - - sudo apt install gnuplot - - -Installation ------------- - -You first have to download the repository - -.. code:: bash - - git clone git@github.com:maxspahn/localPlannerBench.git - -You can install the package using pip as: - -.. code:: bash - - pip3 install . - -If you want to use `poetry `_, you have -to install it first. See their webpage for instructions -https://python-poetry.org/docs/. Once poetry is installed, you can -install the virtual environment with - -.. code:: bash - - poetry update - poetry install - -The virtual environment is entered by - -.. code:: bash - - poetry shell - -Run an experiments ------------------- - -Experiments should be added in separate folder in ``experiments``. Some -default experiments are setup in this repositiory. Navigate there by - -.. code:: bash - - poetry shell - cd experiments/1_fabric_mpc/pointMass - -Then the experiment is run with the command line interface - -.. code:: bash - - ../../../plannerbenchmark/exec/runner -c setup/exp.yaml -p fabric setup/fabric.yaml --render - -Postprocessing --------------- - -The experiments can be postprocessed using the provide executable. When -using poetry, make sure you are in the virtual environment. - -.. code:: bash - - poetry shell - cd path/to/folder/of/experiment - -The you can run the post processor with arguments as - -.. code:: bash - - ../../../plannerbenchmark/exec/postProcessor --exp path/to/experiment -k time2Goal pathLength --plot