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

Add DepthAI PreV3 Support for Robothub #27

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Conversation

psauxo
Copy link

@psauxo psauxo commented Jan 26, 2024

Add DepthAI PreV3 Support for Robothub

I was trying to make an isolated setup based on the existing docker image setup

  • Added the docker file context depthai-v3-git dir with the following files:
  • Introduced a new version rvc2-depthaiV3 into build-images-base.sh
  • Added a new script for building DepthAI from source: context/install-depthai-from-git - used in the previously mentioned Dockerfiles
  • Added a new file with all available versions: scripts/versions.conf
m1 ➜  robothub-images (depthai-preV3-to-rh) ✗ tree -L 3 dockerfiles/depthai-v3-git 
dockerfiles/depthai-v3-git
├── base.Dockerfile
└── builtin-app.Dockerfile

Built images:

m1 ➜  robothub-images (depthai-preV3-to-rh) ✗ docker image ls
REPOSITORY                              TAG                                               IMAGE ID       CREATED              SIZE
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-core                                744914ec446f   2 hours ago          119MB

ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-regular-ros2humble             922d0fd7bcd8   20 minutes ago       1.02GB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-minimal-ros2humble             66ccb828c840   21 minutes ago       576MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-regular                        6b6400cd390d   24 minutes ago       409MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-minimal                        1086e2d5027d   25 minutes ago       283MB


ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-depthaiV3-regular-ros2humble   f7109f730efc   2 hours ago          1.1GB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-depthaiV3-minimal-ros2humble   95f44bbb2bd4   2 hours ago          680MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-depthaiV3-regular              a0f94b84d083   2 hours ago          495MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-depthaiV3-minimal              1aba4dc16549   2 hours ago          390MB

# New Images for rvc2-depthaiV3
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc3-regular-ros2humble             16b942ac7048   3 minutes ago        1.02GB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc3-minimal-ros2humble             158616238e25   6 minutes ago        581MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc3-regular                        cc124193adec   9 minutes ago        415MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc3-minimal                        b8f9c99989c2   17 minutes ago       288MB

ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-depthaiV3-builtin-app          06600bd7d532   2 hours ago          340M
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rae-provisioning-app                9c1c031b2531   10 seconds ago       282MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc3-builtin-app                    0895e0daf3fa   About a minute ago   195MB
ghcr.io/luxonis/robothub-app-v2-amd64   2024.025.1159-rvc2-builtin-app                    c597eb03e1b4   2 minutes ago        190MB

Inside these images:

root@b9696c8027f8:/# pip3 list | grep depthai
depthai                        2.24.0.0.dev0+8b2ade2bb9a90683950c4c6ad867571827042714
depthai-sdk                    1.12.1

>>> dai.Node
<class 'depthai.node.Node'>
>>> dai.message.ImgFrame
<class 'depthai_bind.ImgFrame'>
>>> dai.message.ImgDetections
<class 'depthai_bind.ImgDetections'>

@psauxo psauxo changed the title Add DepthAI PreV3 Support for Robothub based on docker image setup Add DepthAI PreV3 Support for Robothub Jan 26, 2024
@PetrNovota
Copy link
Collaborator

@psauxo do we want to merge this into main when its this testing environment that we will replace in the future anyway?

@psauxo
Copy link
Author

psauxo commented Jan 29, 2024

@psauxo do we want to merge this into main when its this testing environment that we will replace in the future anyway?

I think merging into the main branch isn't necessary at this stage. We can leverage the manual triggers in our GitHub Actions workflows to build and push our Docker images into the GitHub registries for testing purposes. I mean to trigger this workflow publish-images.yml manually to achieve building dev images:
Screenshot 2024-01-29 at 15 05 20

Our current GitHub workflows setup supports this because on workflow_dispatch is used in the workflow:

on:
  workflow_dispatch:
  release:
    types: [published]

Specifically, the IMAGE_REF_NAME is set to robothub-app-v2-dev for non-release events, which suits our testing needs by differentiating test images from production ones:

IMAGE_REF_NAME: ${{ github.event_name == 'release' && 'robothub-app-v2' || 'robothub-app-v2-dev' }}

Additionally, we're using dynamically generated IMAGE_VERSION, ensuring each image built has a unique version identifier. This makes version tracking and management straightforward:

IMAGE_VERSION: ${{ needs.generate-version.outputs.version }}

This setup allows us to effectively test our images without impacting the main branch, maintaining flexibility and control necessary for our current development phase.

Also, it's worth noting that we can build these images now and use them as base images for our depthai-v3 applications.
For example:

FROM ghcr.io/luxonis/robothub-app-v2-dev:2024.275.1315-rvc2-depthaiV3-regular
RUN apt update && apt install -y ffmpeg
RUN pip3 install -U av pytz bitstring

This approach allows us to test the images in a real-world scenario and ensure they meet our requirements. If we encounter any issues or need further modifications, we can always make additional changes to this branch before considering a merge into the main branch.

My proposal is to manually trigger this workflow now. Once the images are built and published, we can proceed to test them in our depthai-v3 applications. What do you think? @PetrNovota

@PetrNovota
Copy link
Collaborator

My proposal is to manually trigger this workflow now. Once the images are built and published, we can proceed to test them in our depthai-v3 applications. What do you think? @PetrNovota

This sounds great!

@psauxo
Copy link
Author

psauxo commented Jan 29, 2024

My proposal is to manually trigger this workflow now. Once the images are built and published, we can proceed to test them in our depthai-v3 applications. What do you think? @PetrNovota

This sounds great!

I have triggered the workflow, all new images are built and published to the registry, you can find new images here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants