From 4ca60e978835508a978a3ac7d3b51c898b4b1538 Mon Sep 17 00:00:00 2001 From: jorou125 <93595148+jorou125@users.noreply.github.com> Date: Fri, 25 Jul 2025 11:50:07 -0400 Subject: [PATCH 1/3] Update docker and docker-compose --- Dockerfile | 24 ++++++++++++++++++++++-- docker-compose.yaml | 21 ++++++++++++++++----- 2 files changed, 38 insertions(+), 7 deletions(-) diff --git a/Dockerfile b/Dockerfile index 77aeb11..d3a6e1e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,9 @@ -#FROM ubuntu:20.04 FROM nvidia/opengl:1.2-glvnd-devel-ubuntu20.04 ENV DEBIAN_FRONTEND noninteractive ENV NVIDIA_VISIBLE_DEVICES all ENV NVIDIA_DRIVER_CAPABILITIES graphics,utility,compute - +ENV LD_LIBRARY_PATH=/usr/lib/wsl/lib +ENV LIBVA_DRIVER_NAME=d3d12 ARG CODE_DIR=/usr/local/src RUN apt update @@ -85,6 +85,26 @@ RUN cd $CODE_DIR && \ EXPOSE 10000/tcp 10000/udp RUN yarp check +# dv-processing +# Add toolchain PPA and install gcc-13/g++-13 +RUN apt update && \ + apt install -y software-properties-common && \ + add-apt-repository ppa:ubuntu-toolchain-r/test && \ + apt update && \ + apt install -y gcc-13 g++-13 + +# Add inivation PPA and install dv-processing dependencies +RUN add-apt-repository ppa:inivation-ppa/inivation && \ + apt-get update && \ + apt-get install -y \ + boost-inivation \ + libcaer-dev \ + libfmt-dev \ + liblz4-dev \ + libzstd-dev \ + libssl-dev && \ + apt-get -y install dv-processing + # event-driven ARG ED_VERSION=main diff --git a/docker-compose.yaml b/docker-compose.yaml index 9c11d84..5763f0a 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,14 +1,24 @@ services: - edopt: + testedopt: image: edopt:latest container_name: edopt privileged: true + environment: + - DISPLAY=${DISPLAY} + - XDG_RUNTIME_DIR=${XDG_RUNTIME_DIR} + - CC=gcc-13 + - CXX=g++-13 + - BOOST_ROOT=/opt/inivation/boost + - BOOST_INCLUDEDIR=/opt/inivation/boost/include + - BOOST_LIBRARYDIR=/opt/inivation/boost/lib volumes: - /dev/bus/usb:/dev/bus/usb - - /tmp/.X11-unix/:/tmp/.X11-unix - environment: - - DISPLAY=unix$DISPLAY + - /tmp/.X11-unix:/tmp/.X11-unix + - /usr/lib/wsl:/usr/lib/wsl + - .:/app network_mode: host + devices: + - /dev/dxg:/dev/dxg deploy: resources: reservations: @@ -16,4 +26,5 @@ services: - driver: nvidia count: all capabilities: [gpu] - command: sleep infinity \ No newline at end of file + stdin_open: true + tty: true \ No newline at end of file From 10bf47fd367c899e5cd6d0b64f45ecd6987d8641 Mon Sep 17 00:00:00 2001 From: jorou125 <93595148+jorou125@users.noreply.github.com> Date: Fri, 25 Jul 2025 11:53:28 -0400 Subject: [PATCH 2/3] update docker files env variables --- Dockerfile | 6 ++++++ docker-compose.yaml | 6 ------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index d3a6e1e..6a4aec3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -105,6 +105,12 @@ RUN add-apt-repository ppa:inivation-ppa/inivation && \ libssl-dev && \ apt-get -y install dv-processing +ENV CC=gcc-13 +ENV CXX=g++-13 +ENV BOOST_ROOT=/opt/inivation/boost +ENV BOOST_INCLUDEDIR=/opt/inivation/boost/include +ENV BOOST_LIBRARYDIR=/opt/inivation/boost/lib + # event-driven ARG ED_VERSION=main diff --git a/docker-compose.yaml b/docker-compose.yaml index 5763f0a..45d113a 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -6,16 +6,10 @@ services: environment: - DISPLAY=${DISPLAY} - XDG_RUNTIME_DIR=${XDG_RUNTIME_DIR} - - CC=gcc-13 - - CXX=g++-13 - - BOOST_ROOT=/opt/inivation/boost - - BOOST_INCLUDEDIR=/opt/inivation/boost/include - - BOOST_LIBRARYDIR=/opt/inivation/boost/lib volumes: - /dev/bus/usb:/dev/bus/usb - /tmp/.X11-unix:/tmp/.X11-unix - /usr/lib/wsl:/usr/lib/wsl - - .:/app network_mode: host devices: - /dev/dxg:/dev/dxg From ad0025459e0817c8cff10d0b551a5555b69d4e4b Mon Sep 17 00:00:00 2001 From: jorou125 <93595148+jorou125@users.noreply.github.com> Date: Thu, 8 Jan 2026 19:10:55 -0500 Subject: [PATCH 3/3] Better docker envs --- docker-compose.yaml | 15 +-- Dockerfile => docker/Inivation/Dockerfile | 12 +- docker/Prophesee/Dockerfile | 135 ++++++++++++++++++++++ 3 files changed, 145 insertions(+), 17 deletions(-) rename Dockerfile => docker/Inivation/Dockerfile (93%) create mode 100644 docker/Prophesee/Dockerfile diff --git a/docker-compose.yaml b/docker-compose.yaml index 45d113a..9c11d84 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,18 +1,14 @@ services: - testedopt: + edopt: image: edopt:latest container_name: edopt privileged: true - environment: - - DISPLAY=${DISPLAY} - - XDG_RUNTIME_DIR=${XDG_RUNTIME_DIR} volumes: - /dev/bus/usb:/dev/bus/usb - - /tmp/.X11-unix:/tmp/.X11-unix - - /usr/lib/wsl:/usr/lib/wsl + - /tmp/.X11-unix/:/tmp/.X11-unix + environment: + - DISPLAY=unix$DISPLAY network_mode: host - devices: - - /dev/dxg:/dev/dxg deploy: resources: reservations: @@ -20,5 +16,4 @@ services: - driver: nvidia count: all capabilities: [gpu] - stdin_open: true - tty: true \ No newline at end of file + command: sleep infinity \ No newline at end of file diff --git a/Dockerfile b/docker/Inivation/Dockerfile similarity index 93% rename from Dockerfile rename to docker/Inivation/Dockerfile index 6a4aec3..6f2ab79 100644 --- a/Dockerfile +++ b/docker/Inivation/Dockerfile @@ -38,16 +38,12 @@ RUN apt update && apt install -y \ gstreamer1.0-plugins-bad \ gstreamer1.0-libav -RUN echo "deb [arch=amd64 trusted=yes] https://apt.prophesee.ai/dists/public/b4b3528d/ubuntu focal sdk" >> /etc/apt/sources.list &&\ - apt update - RUN apt install -y \ libcanberra-gtk-module \ mesa-utils \ ffmpeg \ libboost-program-options-dev \ - libopencv-dev \ - metavision-sdk + libopencv-dev #my favourites RUN apt update && apt install -y \ @@ -115,7 +111,8 @@ ENV BOOST_LIBRARYDIR=/opt/inivation/boost/lib # event-driven ARG ED_VERSION=main RUN cd $CODE_DIR &&\ - git clone --depth 1 --branch $ED_VERSION https://github.com/robotology/event-driven.git &&\ + git clone --depth 1 --branch $ED_VERSION https://github.com/jorou125/event-driven-DVXplorerMicro.git &&\ + mv event-driven-DVXplorerMicro event-driven && \ cd event-driven &&\ mkdir build && cd build &&\ cmake .. &&\ @@ -139,7 +136,8 @@ RUN ssh-keyscan github.com > /root/.ssh/known_hosts ARG GIT_BRANCH=main RUN cd $CODE_DIR &&\ - git clone https://github.com/event-driven-robotics/EDOPT.git &&\ + git clone https://github.com/jorou125/DV-EDOPT.git &&\ + mv DV-EDOPT EDOPT &&\ cd EDOPT &&\ git checkout $GIT_BRANCH diff --git a/docker/Prophesee/Dockerfile b/docker/Prophesee/Dockerfile new file mode 100644 index 0000000..77aeb11 --- /dev/null +++ b/docker/Prophesee/Dockerfile @@ -0,0 +1,135 @@ +#FROM ubuntu:20.04 +FROM nvidia/opengl:1.2-glvnd-devel-ubuntu20.04 +ENV DEBIAN_FRONTEND noninteractive +ENV NVIDIA_VISIBLE_DEVICES all +ENV NVIDIA_DRIVER_CAPABILITIES graphics,utility,compute + +ARG CODE_DIR=/usr/local/src + +RUN apt update + +#basic environment +RUN apt install -y \ + ca-certificates \ + build-essential \ + git \ + cmake \ + cmake-curses-gui \ + libace-dev \ + libassimp-dev \ + libglew-dev \ + libglfw3-dev \ + libglm-dev \ + libeigen3-dev + +# Suggested dependencies for YARP +RUN apt update && apt install -y \ + qtbase5-dev qtdeclarative5-dev qtmultimedia5-dev \ + qml-module-qtquick2 qml-module-qtquick-window2 \ + qml-module-qtmultimedia qml-module-qtquick-dialogs \ + qml-module-qtquick-controls qml-module-qt-labs-folderlistmodel \ + qml-module-qt-labs-settings \ + libqcustomplot-dev \ + libgraphviz-dev \ + libjpeg-dev \ + libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev \ + gstreamer1.0-plugins-base \ + gstreamer1.0-plugins-good \ + gstreamer1.0-plugins-bad \ + gstreamer1.0-libav + +RUN echo "deb [arch=amd64 trusted=yes] https://apt.prophesee.ai/dists/public/b4b3528d/ubuntu focal sdk" >> /etc/apt/sources.list &&\ + apt update + +RUN apt install -y \ + libcanberra-gtk-module \ + mesa-utils \ + ffmpeg \ + libboost-program-options-dev \ + libopencv-dev \ + metavision-sdk + +#my favourites +RUN apt update && apt install -y \ + vim \ + gdb + +# Github CLI +RUN (type -p wget >/dev/null || (apt update && apt-get install wget -y)) \ + && mkdir -p -m 755 /etc/apt/keyrings \ + && wget -qO- https://cli.github.com/packages/githubcli-archive-keyring.gpg | tee /etc/apt/keyrings/githubcli-archive-keyring.gpg > /dev/null \ + && chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg \ + && echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | tee /etc/apt/sources.list.d/github-cli.list > /dev/null \ + && apt update \ + && apt install gh -y + +# YCM +ARG YCM_VERSION=v0.15.2 +RUN cd $CODE_DIR && \ + git clone --depth 1 --branch $YCM_VERSION https://github.com/robotology/ycm.git && \ + cd ycm && \ + mkdir build && cd build && \ + cmake .. && \ + make -j `nproc` install + + +# YARP +ARG YARP_VERSION=v3.8.0 +RUN cd $CODE_DIR && \ + git clone --depth 1 --branch $YARP_VERSION https://github.com/robotology/yarp.git &&\ + cd yarp &&\ + mkdir build && cd build &&\ + cmake .. &&\ + make -j `nproc` install + +EXPOSE 10000/tcp 10000/udp +RUN yarp check + + +# event-driven +ARG ED_VERSION=main +RUN cd $CODE_DIR &&\ + git clone --depth 1 --branch $ED_VERSION https://github.com/robotology/event-driven.git &&\ + cd event-driven &&\ + mkdir build && cd build &&\ + cmake .. &&\ + make -j `nproc` install + +# object-tracking-six-dof + +###################### +# set github ssh keys # +####################### + +RUN apt install -y \ + openssh-client git \ + libmysqlclient-dev \ + libsm6 libxext6 + +# Authorize SSH Host +RUN mkdir -p /root/.ssh && \ + chmod 0700 /root/.ssh +RUN ssh-keyscan github.com > /root/.ssh/known_hosts + +ARG GIT_BRANCH=main +RUN cd $CODE_DIR &&\ + git clone https://github.com/event-driven-robotics/EDOPT.git &&\ + cd EDOPT &&\ + git checkout $GIT_BRANCH + +# SUPERIMPOSEMESH +ARG SIML_VERSION=devel +RUN cd $CODE_DIR &&\ + git clone --depth 1 --branch $SIML_VERSION https://github.com/robotology/superimpose-mesh-lib.git &&\ + cd superimpose-mesh-lib &&\ + git apply $CODE_DIR/EDOPT/superimposeroi.patch &&\ + mkdir build && cd build &&\ + cmake .. &&\ + make -j `nproc` install + +# Build EDOPT +RUN cd $CODE_DIR &&\ + cd EDOPT/code &&\ + mkdir build && cd build &&\ + cmake .. &&\ + make -j `nproc` \ No newline at end of file