-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Version 5.0.0 refactors the dynamical systems and controllers libraries with a factory pattern and parameter interface for easier creation, manipulation and substitution of these classes. This major change breaks any implementations using dynamical systems or controllers from the prior version. See the updated documentation for usage guidelines for the new DynamicalSystemsFactory and ControllerFactory. This release also includes substantial improvements to the python bindings, including class bindings for the dynamical systems library. Additional fixes and improvements have been made throughout the framework. Refer to the CHANGELOG for more information.
- Loading branch information
Showing
181 changed files
with
6,128 additions
and
3,751 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,44 @@ | ||
#!/usr/bin/env bash | ||
# Build a docker image to compile the library and run tests | ||
MULTISTAGE_TARGET="runtime-demonstrations" | ||
|
||
REBUILD=0 | ||
while getopts 'r' opt; do | ||
case $opt in | ||
r) REBUILD=1 ;; | ||
*) echo 'Error in command line parsing' >&2 | ||
exit 1 | ||
esac | ||
done | ||
shift "$(( OPTIND - 1 ))" | ||
|
||
NAME=$(echo "${PWD##*/}" | tr _ -)/$MULTISTAGE_TARGET | ||
TAG="latest" | ||
TARGET_SCRIPT=${1} | ||
IMAGE_NAME=epfl-lasa/control-libraries/control-loop-examples | ||
IMAGE_TAG=latest | ||
|
||
BUILD_FLAGS=(--target "${MULTISTAGE_TARGET}") | ||
BUILD_FLAGS+=(-t "${NAME}:${TAG}") | ||
HELP_MESSAGE="Usage: run-demo.sh [-s <script>] [-r] [-v] | ||
Options: | ||
-s, --script If provided, the desired script that should be | ||
executed when starting the container. | ||
-r, --rebuild Rebuild the image using the docker | ||
--no-cache option. | ||
-v, --verbose Use the verbose option during the building | ||
process. | ||
-h, --help Show this help message. | ||
" | ||
|
||
if [ "$REBUILD" -eq 1 ]; then | ||
BUILD_FLAGS+=(--no-cache) | ||
fi | ||
BUILD_FLAGS=() | ||
TARGET_SCRIPT="" | ||
while [[ $# -gt 0 ]]; do | ||
opt="$1" | ||
case $opt in | ||
-s|--script) TARGET_SCRIPT="$2"; shift;; | ||
-r|--rebuild) BUILD_FLAGS+=(--no-cache); shift ;; | ||
-v|--verbose) BUILD_FLAGS+=(--progress=plain); shift ;; | ||
-h|--help) echo "${HELP_MESSAGE}" ; exit 0 ;; | ||
*) echo 'Error in command line parsing' >&2 | ||
echo -e "\n${HELP_MESSAGE}" | ||
exit 1 | ||
esac | ||
done | ||
|
||
MULTISTAGE_SOURCE_TARGET="source-dependencies" | ||
DOCKER_BUILDKIT=1 docker build --target "${MULTISTAGE_SOURCE_TARGET}" \ | ||
-t "control-libraries/${MULTISTAGE_SOURCE_TARGET}" \ | ||
-f ../../source/Dockerfile.source ../../source || exit | ||
DOCKER_BUILDKIT=1 docker build "${BUILD_FLAGS[@]}" . || exit | ||
docker pull ghcr.io/epfl-lasa/control-libraries/development-dependencies | ||
DOCKER_BUILDKIT=1 docker build --target install \ | ||
-t epfl-lasa/control-libraries/source:install \ | ||
--build-arg BUILD_TESTING=OFF \ | ||
"${BUILD_FLAGS[@]}" \ | ||
-f ../../source/Dockerfile.source ../../source || exit 1 | ||
DOCKER_BUILDKIT=1 docker build "${BUILD_FLAGS[@]}" . -t "${IMAGE_NAME}:${IMAGE_TAG}" || exit 1 | ||
|
||
if [ -z "${1}" ]; then | ||
docker run -it --rm "${NAME}:${TAG}" | ||
if [ -z "${TARGET_SCRIPT}" ]; then | ||
docker run -it --rm "${IMAGE_NAME}:${IMAGE_TAG}" | ||
else | ||
docker run --rm "${NAME}:${TAG}" "./${1}" | ||
docker run --rm "${IMAGE_NAME}:${IMAGE_TAG}" "./${TARGET_SCRIPT}" | ||
fi |
Oops, something went wrong.