From: Jiri Vlasak Date: Wed, 28 Jul 2021 12:37:11 +0000 (+0200) Subject: Update readme X-Git-Tag: v0.5.0~8 X-Git-Url: http://rtime.felk.cvut.cz/gitweb/hubacji1/iamcar2.git/commitdiff_plain/033acbc288af2df6014d13eef024e0e26abbf259?hp=d144009b7377d892141fa3434677fac63d230a03 Update readme --- diff --git a/README.md b/README.md index de10eb8..cdc6669 100644 --- a/README.md +++ b/README.md @@ -1,154 +1,51 @@ -# I am car, too -*I am car, too* puts together multiple libraries and run some automated parking -tests. +I am car, too +============= + +__I am car, too__ puts together some libraries to run some tests on some +scenarios. + +This project uses git submodules, run `git submodule update --init` when cloned. + +License +------- -# License The project is published under [MIT License][1]. [1]: ./LICENSE -# Build +Build +----- + To build the project run the following commands: -``` -mkdir build -cd build -cmake ../ -make -``` + + mkdir build + cd build + cmake ../ + make To build with ninja: -``` -mkdir build -cd build -cmake -DCMAKE_BUILD_TYPE=Release -G Ninja ../ -ninja -v -``` - -## Required libraries -- libjsoncpp-dev (`apt install libjsoncpp-dev`) -- [libpsp](http://rtime.felk.cvut.cz/gitweb/hubacji1/psp.git) - - [libbcar](http://rtime.felk.cvut.cz/gitweb/hubacji1/bcar.git) - - libpslot (part of libbcar repository) -- [librrts](http://rtime.felk.cvut.cz/gitweb/hubacji1/rrts.git) - - libbcar (see above) - -# Tests -Files in `src/` folder named `testX.cc` where `X` is integer are tests. All -tests expects JSON fromatted *scenario* on standard input and outputs JSON -formatted *plan* on standard output. Both, *scenario* and *plan* can be plotted -with `plot_json_objects_scenario.py` script. - -## JSON formatted *scenario* -The following properties are expected: -- `init`: list of 3 numbers (`x`, `y`, `heading`). -- `obst`: list of polygon obstacles, where polygon obstacle is list of - coordinates, and coordinate is a list of 2 numbers (`x`, `y`). -- `slot`: list of parking slots, where parking slot is a list of 4 coordinates, - and coordinate is a list of 2 numbers (`x`, `y`). - -## JSON formatted *plan* -The following properties are expected to extend *scenario* properties: -- `goal`: list of 3 numbers (`x`, `y`, `heading`). -- `goals`: list of possible goals `[(x, y, h), ...]`. -- `path`: list of poses, where pose is list of 3 numbers (`x`, `y`, `heading`). - -## JSON formatted *stats* -The following are expected in the output along with *plan*: -- `time`: elapsed time. -- `iterations`: number of iterations of algorithm. -- `cost`: path cost. -- `cusps-in-path`: the number of nodes with direction change in path. -- `connecteds-in-path`: the number of nodes almost same (connected) in path. -- `nodes`: overall number of nodes. - -## Test files -There is a list of test files `src/testN.cc`, where `N` stands for: - -1. *PSPlanner*: parking slot planner. -2. *RRTS*: rapidly-exploring random tree star. -3. *RRTExt2*: RRT\* w/[cute c2][] library for collision detection. -4. *RRTCE1*: cute, RS-heur. -5. *RRTCE2*: cute, RS-Euclid. -6. *RRTCE3*: cute, RS-RS. -7. *RRTS*: pure RRT\* run in 1 second interval multiple times. -8. *RRTCE5*: cute, grid, RS-Euclid. -9. *RRTCE7*: cute, grid, RS-Euclid, Dijkstra. -10. [behavior tree][] w/*RRTCE7*: cute, grid, RS-Euclid, Dijkstra. -11. *RRTCE4*: cute, grid, RS-heur. -12. *RRTCE6*: cute, grid, RS-RS. -13. *RRTCE8*: cute, grid, RS-RS, dijkstra (`ce8`). -14. *RRTCE9*: cute, grid, RS-heur, dijkstra (`ce9`). -15. *RRTCE10*: cute, Dijkstra, 2D k-d tree, RS-RS. -16. *RRTCE11*: cute, Dijkstra, 2D k-d tree, RS-Euclid. -17. *RRTCE12*: cute, Dijkstra, 2D k-d tree, RS-heur. -18. *RRTCE13*: cute, Dijkstra, 3D k-d tree, RS-RS. -19. *RRTCE14*: cute, Dijkstra, 3D k-d tree, RS-heur. -20. *RRTCE15*: cute, Dijkstra, 3D grid, RS-RS. -21. *RRTCE16*: cute, Dijkstra, 3D grid, RS-heur. -22. *RRTCE13*: psp, cute, Dijkstra, RS-RS, 3D tree. -23. *RRTCE14*: psp, cute, Dijkstra, RS-M, 3D tree. -24. *RRTCE15*: psp, cute, Dijkstra, RS-RS, 3D grid. -25. *RRTCE16*: psp, cute, Dijkstra, RS-M, 3D grid. -26. *RRTCE11*: psp, cute, Dijkstra, RS-E, 2D tree -27. *RRTCE7*: psp, cute, Dijkstra, RS-E, 2D grid - -28. *RRTCE3*: psp, cute, RS-RS -29. *RRTCE2*: psp, cute, RS-E -30. *RRTCE1*: psp, cute, RS-M -31. *RRTCE17*: psp, cute, RS-H - -32. *RRTCE18*: psp, cute, 2D grid, RS-RS -33. *RRTCE19*: psp, cute, 2D grid, RS-E -34. *RRTCE20*: psp, cute, 2D grid, RS-M -35. *RRTCE21*: psp, cute, 2D grid, RS-H - -36. *RRTCE22*: psp, cute, 2D tree, RS-RS -37. *RRTCE23*: psp, cute, 2D tree, RS-E -38. *RRTCE24*: psp, cute, 2D tree, RS-M -39. *RRTCE25*: psp, cute, 2D tree, RS-H - -40. *RRTCE26*: psp, cute, 3D grid, RS-RS -41. *RRTCE27*: psp, cute, 3D grid, RS-E -42. *RRTCE28*: psp, cute, 3D grid, RS-M -43. *RRTCE29*: psp, cute, 3D grid, RS-H - -44. *RRTCE30*: psp, cute, 3D tree, RS-RS -45. *RRTCE31*: psp, cute, 3D tree, RS-E -46. *RRTCE32*: psp, cute, 3D tree, RS-M -47. *RRTCE33*: psp, cute, 3D tree, RS-H - -48. *RRTCE34*: psp, cute, gz, Dijkstra, 3D tree, RS-H, diff. steer -49. *RRTCE35*: psp, cute, gz, Dijkstra2, 3D tree, RS-H - -Template for tests is in file `src/test-template.cc`. - -[cute c2]: https://github.com/RandyGaul/cute_headers/blob/master/cute_c2.h -[behavior tree]: https://github.com/arvidsson/BrainTree - -# Contribute -Use [OneFlow][3] branching model and keep the [changelog][4]. - -Write [great git commit messages][5]: -1. Separate subject from body with a blank line. -2. Limit the subject line to 50 characters. -3. Capitalize the subject line. -4. Do not end the subject line with a period. -5. Use the imperative mood in the subject line. -6. Wrap the body at 72 characters. -7. Use the body to explain what and why vs. how. - -When adding feature or hotfix, use [Test-driven development (TDD)][2]: -1. Add tests to `ut` folder, add methods declaration, basic structure. -2. Run tests (just `make` in `build` folder), check that tests *fail*. -3. Implement functionality. -4. Run tests, check that tests *pass*. -5. Refactor. - -[2]: https://en.wikipedia.org/wiki/Test-driven_development -[3]: https://www.endoflineblog.com/oneflow-a-git-branching-model-and-workflow -[4]: ./CHANGELOG.md -[5]: https://chris.beams.io/posts/git-commit/ - -# Documentation -The documentation is generated by Doxygen, at least version `1.8.15` is needed. -Just run `doxygen` in the project root directory. + + mkdir build + cd build + cmake -DCMAKE_BUILD_TYPE=Release -G Ninja ../ + ninja -v + +Scenarios +========= + +All the scenarios are in the directories named `scenarios-*`. Each scenario +contains at least `init`, `slot`, and the list of `obst`acles. + +Tests +===== + +Tests are build from within the cmake file. Tests are named `testN` where `N` is +the test's identifier. All tests expects JSON fromatted scenario on standard +input and outputs JSON that can vary, but at minimum contains `goal` computed +for the parking `slot`, `path` from `init` to `goal` that avoid `obst`acles, if +such a path exists, `goal_cc` (cumulative cost), and elapsed `time`. + +Input and/or otput of the tests can be plotted with +`plot_json_objects_scenario.py` script. + +`src/` directory contains templates used to build tests.