Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement Set-Based TPIK and perform initial cleanup #17

Merged
merged 34 commits into from
Aug 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
cb86d76
started jacobian implementation
evan-palmer Jul 17, 2023
4dc1366
Implemented jacobians for primary tasks
evan-palmer Jul 18, 2023
c34f093
finished (untested) initial version of jacobian implementation
evan-palmer Jul 19, 2023
82f50da
Saving DH param stuff before I delete in case of revert
evan-palmer Jul 19, 2023
9f0353a
One more dh save
evan-palmer Jul 19, 2023
98330ef
Finished initial untested jacobians and started constraint implementa…
evan-palmer Jul 20, 2023
a3e5f4a
go crazy
evan-palmer Jul 21, 2023
3a7854c
Finished jacobian unit tests
evan-palmer Jul 21, 2023
312c864
Cleaned up jacobian implementation in favor of tasks
evan-palmer Jul 22, 2023
6ef5747
Went back on task object idea
evan-palmer Jul 23, 2023
10dbd9b
started controller
evan-palmer Jul 24, 2023
d4cd781
Save point before I go back to task classes... again
evan-palmer Jul 24, 2023
fd44b9f
Improved task interface
evan-palmer Jul 24, 2023
2783ca5
Implemented base tpik
evan-palmer Jul 25, 2023
00ef43c
Implemented hierarchy and modes
evan-palmer Jul 26, 2023
67ff656
Finished initial implementation of set based tpik
evan-palmer Jul 26, 2023
2402181
Wrote hierarchy unit tests and started debugging
evan-palmer Jul 26, 2023
e18cf38
Fixed set tasks
evan-palmer Jul 27, 2023
ff8e43f
Fixed axis d bug, resolved solution selection bug, and added nvidia d…
evan-palmer Jul 27, 2023
e875be0
Added nominal configuration task
evan-palmer Jul 27, 2023
3e05444
Fixed devcontainer and most of end effector tracking
evan-palmer Jul 28, 2023
46909bb
Debugging uvms position jacobian
evan-palmer Jul 28, 2023
d4ebaad
WHY WONT THE POSITION JACOBIAN WORK FOR THE LOVE OF GOD
evan-palmer Jul 29, 2023
4d2f7ad
i believe in a world free from the curse of singularities
evan-palmer Jul 29, 2023
5f068ae
wip: started cleanup
evan-palmer Jul 30, 2023
90025d1
wip: removed angler msgs
evan-palmer Jul 30, 2023
8f46dbe
wip: fixed waypoint planner
evan-palmer Jul 31, 2023
f310621
wip: redid the description package and launch file
evan-palmer Jul 31, 2023
ec2d169
More bug fixes from cleanup
evan-palmer Aug 1, 2023
133ae85
Finished initial cleanup and tpik implementation
evan-palmer Aug 2, 2023
48f6f69
Cleaned up readme
evan-palmer Aug 2, 2023
72e3cd3
Readme changes
evan-palmer Aug 2, 2023
05d2a55
More readme stuff
evan-palmer Aug 2, 2023
0a881a6
Fixed precommit and added iron to ci
evan-palmer Aug 2, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
{
"dockerFile": ".docker/Dockerfile",
"context": ".",
"dockerFile": "../../.docker/Dockerfile",
"context": "../..",
"build": {
"args": {
"WORKSPACE": "${containerWorkspaceFolder}",
"ROS_DISTRO": "rolling"
}
},
"target": "develop"
},
"remoteUser": "angler",
"runArgs": [
Expand Down
127 changes: 127 additions & 0 deletions .devcontainer/nvidia/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
{
"dockerFile": "../../.docker/Dockerfile",
"context": "../..",
"build": {
"args": {
"WORKSPACE": "${containerWorkspaceFolder}",
"ROS_DISTRO": "rolling"
},
"target": "develop-nvidia"
},
"remoteUser": "angler",
"runArgs": [
"--network=host",
"--cap-add=SYS_PTRACE",
"--security-opt=seccomp:unconfined",
"--security-opt=apparmor:unconfined",
"--volume=/tmp/.X11-unix:/tmp/.X11-unix",
"--volume=/mnt/wslg:/mnt/wslg",
"--gpus=all"
],
"containerEnv": {
"DISPLAY": "${localEnv:DISPLAY}",
"WAYLAND_DISPLAY": "${localEnv:WAYLAND_DISPLAY}",
"XDG_RUNTIME_DIR": "${localEnv:XDG_RUNTIME_DIR}",
"PULSE_SERVER": "${localEnv:PULSE_SERVER}",
"LIBGL_ALWAYS_SOFTWARE": "1",
"QT_X11_NO_MITSHM": "1"
},
"customizations": {
"vscode": {
"settings": {
"files.associations": {
"*.repos": "yaml",
"*.world": "xml",
"*.xacro": "xml",
"*.srdf": "xml",
"*.rviz": "yaml",
"*.config": "xml",
"*.sdf": "xml"
},
"terminal.integrated.defaultProfile.linux": "bash",
"files.insertFinalNewline": true,
"files.trimTrailingWhitespace": true,
"editor.formatOnSave": true,
"editor.tabSize": 2,
"xml.format.maxLineWidth": 100,
"json.format.enable": true,
"python.linting.enabled": true,
"python.linting.flake8Enabled": true,
"python.linting.pylintEnabled": false,
"python.linting.pydocstyleEnabled": true,
"python.linting.mypyEnabled": true,
"python.formatting.provider": "black",
"autoDocstring.startOnNewLine": false,
"autoDocstring.docstringFormat": "google-notypes",
"isort.args": ["--profile", "black"],
"isort.check": true,
"python.autoComplete.extraPaths": [
"/opt/ros/rolling/lib/python3.10/site-packages/",
"/opt/ros/rolling/local/lib/python3.10/dist-packages/",
"${workspaceFolder}/install/"
],
"python.analysis.extraPaths": [
"/opt/ros/rolling/lib/python3.10/site-packages/",
"/opt/ros/rolling/local/lib/python3.10/dist-packages/",
"${workspaceFolder}/install/"
],
"C_Cpp.default.intelliSenseMode": "linux-gcc-x86",
"C_Cpp.clang_format_fallbackStyle": "Google",
"C_Cpp.codeAnalysis.clangTidy.enabled": true,
"C_Cpp.codeAnalysis.clangTidy.runAutomatically": true,
"clang-format.executable": "/usr/bin/clang-format-14",
"[cpp]": {
"editor.rulers": [100],
"editor.tabSize": 2,
"editor.defaultFormatter": "xaver.clang-format"
},
"[python]": {
"editor.tabSize": 4,
"editor.rulers": [90],
"editor.codeActionsOnSave": {
"source.organizeImports": true
}
},
"[dockerfile]": {
"editor.quickSuggestions": {
"strings": true
},
"editor.defaultFormatter": "ms-azuretools.vscode-docker",
"editor.tabSize": 4
},
"[json]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[xml]": {
"editor.defaultFormatter": "redhat.vscode-xml"
},
"[markdown]": {
"editor.rulers": [80],
"editor.defaultFormatter": "DavidAnson.vscode-markdownlint"
},
"search.exclude": {
"**/build": true,
"**/install": true,
"**/log": true
}
},
"extensions": [
"ms-azuretools.vscode-docker",
"ms-python.python",
"njpwerner.autodocstring",
"cschlosser.doxdocgen",
"ms-vscode.cpptools",
"redhat.vscode-xml",
"redhat.vscode-yaml",
"josetr.cmake-language-support-vscode",
"smilerobotics.urdf",
"DavidAnson.vscode-markdownlint",
"esbenp.prettier-vscode",
"xaver.clang-format",
"ms-python.isort",
"ms-python.flake8",
"ms-python.black-formatter"
]
}
}
}
92 changes: 76 additions & 16 deletions .docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,8 @@ RUN apt-get -q update \
&& apt-get clean -y \
&& rm -rf /var/lib/apt/lists/*

# Install Qualisys Python SDK
# This isn't available as a rosdep, so we need to install
# it manually
RUN python3 -m pip install qtm
# Install the Python requirements that aren't available as rosdeps
RUN python3 -m pip install -r $(pwd)/src/angler/requirements-build.txt

# Install gstreamer
RUN apt-get -q update \
Expand Down Expand Up @@ -178,7 +176,8 @@ RUN apt-get -q update \
RUN . "/opt/ros/${ROS_DISTRO}/setup.sh" \
&& colcon build \
# Update /ros_entrypoint.sh to source the workspace
&& sed -i "s#/opt/ros/\$ROS_DISTRO/setup.bash#$USER_WORKSPACE/setup.sh#g" /ros_entrypoint.sh
&& sed -i "s#/opt/ros/\$ROS_DISTRO/setup.bash#$USER_WORKSPACE/setup.sh#g" /ros_entrypoint.sh \
&& echo "source ${USER_WORKSPACE}/setup.sh" >> /home/$USERNAME/.bashrc

####################################################
# develop: Setup the image for development purposes
Expand All @@ -192,6 +191,9 @@ WORKDIR $ROS_UNDERLAY/..

COPY . src/angler

# Install debugging/linting Python packages
RUN python3 -m pip install -r $(pwd)/src/angler/requirements-dev.txt

RUN apt-get -q update \
&& apt-get -q -y upgrade \
&& vcs import src < src/angler/angler.repos \
Expand All @@ -209,26 +211,84 @@ RUN apt-get -q update \
iputils-ping \
net-tools \
gdb \
nano \
&& apt-get autoremove -y \
&& apt-get clean -y \
&& rm -rf /var/lib/apt/lists/*

COPY .docker/entrypoints/dev.sh /

# WARNING: This is a temporary solution for disabling the setuputils installation warning
ENV PYTHONWARNINGS="ignore"

ARG WORKSPACE
RUN echo "if [ -f ${WORKSPACE}/install/setup.bash ]; then source ${WORKSPACE}/install/setup.bash; fi" >> /home/$USERNAME/.bashrc \
&& echo "if [ -f /opt/ros/${ROS_DISTRO}/setup.bash ]; then source /opt/ros/${ROS_DISTRO}/setup.bash; fi" >> /home/$USERNAME/.bashrc \
# Expose the environment variables to the non-root user
&& echo "if [ -f /sim.sh ]; then source /sim.sh; fi" >> /home/$USERNAME/.bashrc \
&& echo "if [ -f /dev.sh ]; then source /dev.sh; fi" >> /home/$USERNAME/.bashrc


######################################################################################
# develop-nvidia: Setup the image for development purposes with NVIDIA driver support
######################################################################################
FROM deps as develop-nvidia

# Install NVIDIA software
RUN apt-get update \
&& apt-get install -y -qq --no-install-recommends \
libglvnd0 \
libgl1 \
libglx0 \
libegl1 \
libxext6 \
libx11-6

# Env vars for the nvidia-container-runtime.
ENV NVIDIA_VISIBLE_DEVICES all
ENV NVIDIA_DRIVER_CAPABILITIES graphics,utility,compute
ENV QT_X11_NO_MITSHM 1

ENV GZ_VERSION=garden
ENV ROS_UNDERLAY /root/ws_angler/install
ENV DEBIAN_FRONTEND=noninteractive
WORKDIR $ROS_UNDERLAY/..

COPY . src/angler

# Install debugging/linting Python packages
RUN python3 -m pip install \
pre-commit \
mypy \
isort \
flake8 \
black \
setuptools==58.2.0
RUN python3 -m pip install -r $(pwd)/src/angler/requirements-dev.txt

RUN apt-get -q update \
&& apt-get -q -y upgrade \
&& vcs import src < src/angler/angler.repos \
&& rosdep update \
&& rosdep install -y --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} --as-root=apt:false --skip-keys="gz-transport12 gz-sim7 gz-math7 gz-msgs9 gz-plugin2" \
&& rm -rf src \
&& apt-get autoremove -y \
&& apt-get clean -y \
&& rm -rf /var/lib/apt/lists/*

# Install development tools
RUN apt-get -q update \
&& apt-get -q -y upgrade \
&& apt-get -q install --no-install-recommends -y \
iputils-ping \
net-tools \
gdb \
nano \
&& apt-get autoremove -y \
&& apt-get clean -y \
&& rm -rf /var/lib/apt/lists/*

COPY .docker/entrypoints/dev.sh /

# WARNING: This is a temporary solution for disabling the setuputils installation warning
ENV PYTHONWARNINGS="ignore"

ARG WORKSPACE
RUN echo "if [ -f ${WORKSPACE}/install/setup.bash ]; then source ${WORKSPACE}/install/setup.bash; fi" >> /home/$USERNAME/.bashrc \
&& echo "if [ -f /opt/ros/${ROS_DISTRO}/setup.bash ]; then source /opt/ros/${ROS_DISTRO}/setup.bash; fi" >> /home/$USERNAME/.bashrc \
# Expose the environment variables to the non-root user
&& echo "if [ -f /ros_entrypoint.sh ]; then source /ros_entrypoint.sh; fi" >> /home/$USERNAME/.bashrc

ENTRYPOINT [ "/ros_entrypoint.sh" ]
CMD ["bash"]
&& echo "if [ -f /sim.sh ]; then source /sim.sh; fi" >> /home/$USERNAME/.bashrc \
&& echo "if [ -f /dev.sh ]; then source /dev.sh; fi" >> /home/$USERNAME/.bashrc
5 changes: 4 additions & 1 deletion .docker/entrypoints/sim.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,14 @@ export GZ_SIM_SYSTEM_PLUGIN_PATH=$HOME/ardupilot_gazebo/build:$GZ_SIM_SYSTEM_PLU
# Optional: add ardupilot_gazebo models and worlds
export GZ_SIM_RESOURCE_PATH=$HOME/ardupilot_gazebo/models:$HOME/ardupilot_gazebo/worlds:$GZ_SIM_RESOURCE_PATH

# Add alpha models
# Add alpha meshes
export GZ_SIM_RESOURCE_PATH=$HOME/ws_angler/src/alpha/alpha_description/meshes:$GZ_SIM_RESOURCE_PATH

# Add blue models and worlds
export GZ_SIM_RESOURCE_PATH=$HOME/ws_angler/src/blue/blue_description/gazebo/models:$HOME/ws_angler/src/blue/blue_description/gazebo/worlds:$GZ_SIM_RESOURCE_PATH

# Add blue meshes
export GZ_SIM_RESOURCE_PATH=$HOME/ws_angler/src/blue/blue_description/meshes:$GZ_SIM_RESOURCE_PATH

# Build ros_gz for Gazebo Garden
export GZ_VERSION=garden
5 changes: 2 additions & 3 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@
!angler_bringup
!angler_planning
!angler_msgs
<<<<<<< HEAD
!angler_mux
!angler.repos
!.docker/entrypoints
=======
>>>>>>> origin/develop
!requirements-build.txt
!requirements-dev.txt
5 changes: 0 additions & 5 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,6 @@ toward closing.

- Fixes # (issue)

## Files Changed

Please provide a list of all files changed and a summary of the changes made to
the respective files.

## Testing

Please provide a clear and concise description of the testing performed.
2 changes: 2 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ jobs:
ROS_DISTRO: rolling
- IMAGE: humble-ci
ROS_DISTRO: humble
- IMAGE: iron-ci
ROS_DISTRO: iron
steps:
- name: Checkout repository
uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ROS_DISTRO: [humble, rolling]
ROS_DISTRO: [humble, rolling, iron]
runs-on: ubuntu-latest
permissions:
packages: write
Expand Down
Loading
Loading