-
Notifications
You must be signed in to change notification settings - Fork 9
move to ssl-protocol-def sm #23
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
Open
guyfleeman
wants to merge
9
commits into
RoboCup-SSL:master
Choose a base branch
from
guyfleeman:dev/will/ssl-protocol-defs
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
57c7b90
move to ssl-protocol-def sm
guyfleeman 4419ecb
CMake cleanup
guyfleeman fd29ca6
move proto submodule forward to main
guyfleeman 335af2e
Merge branch 'master' of https://github.com/TIGERs-Mannheim/vision-pr…
guyfleeman 75159fe
add new proto to python system
guyfleeman 41e9174
add GH CI, add flake.nix which provides Eigne5 as a stop gap dev env
guyfleeman 51ef03e
Revert use of canonical angles
b6b8db5
Merge remote-tracking branch 'origin/revert-cananonical' into dev/wil…
guyfleeman 0f8455b
revert flake to Eigen 3.X to match apicall revert, ping ffmpeg to 8.X…
guyfleeman File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,84 @@ | ||
| name: CI | ||
|
|
||
| on: | ||
| push: | ||
| branches: [master] | ||
| pull_request: | ||
|
|
||
| # A second push to the same PR makes the first run's result irrelevant. | ||
| concurrency: | ||
| group: ${{ github.workflow }}-${{ github.ref }} | ||
| cancel-in-progress: true | ||
|
|
||
| jobs: | ||
| build: | ||
| name: Build (nix) | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| # The protocol definitions are a submodule; without them CMake fails at | ||
| # configure time with the "run git submodule update" message. | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| submodules: recursive | ||
|
|
||
| - uses: DeterminateSystems/nix-installer-action@main | ||
| - uses: DeterminateSystems/magic-nix-cache-action@main | ||
|
|
||
| # The dev shell pins eigen_5. Ubuntu ships 3.4.0 through at least 26.04 | ||
| # LTS, which lacks Matrix::canonicalEulerAngles() -- so this cannot be an | ||
| # apt-based job without patching the source. | ||
| - name: Build all targets | ||
| run: | | ||
| nix develop --command bash -c ' | ||
| cmake -B build . | ||
| make -C build -j"$(nproc)" vision_processor geometry_benchmark blob_benchmark | ||
| ' | ||
|
|
||
| python: | ||
| name: Python (wrapper_backend) | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| with: | ||
| submodules: recursive | ||
|
|
||
| - uses: DeterminateSystems/nix-installer-action@main | ||
| - uses: DeterminateSystems/magic-nix-cache-action@main | ||
|
|
||
| # Importing wrapper_backend runs protoc against the submodule and | ||
| # generates wrapper_backend/proto/, which mypy needs on its path even | ||
| # though it excludes the generated files themselves. | ||
| - name: Lint and type check | ||
| run: | | ||
| nix develop --command bash -c ' | ||
| uv sync --locked | ||
| uv run python -c "import wrapper_backend" | ||
| uv run ruff check wrapper_backend/ | ||
| uv run ruff format --check wrapper_backend/ | ||
| uv run mypy | ||
| ' | ||
|
|
||
| frontend: | ||
| name: Frontend (wrapper-frontend) | ||
| runs-on: ubuntu-latest | ||
| defaults: | ||
| run: | ||
| working-directory: wrapper-frontend | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - uses: actions/setup-node@v4 | ||
| with: | ||
| node-version: 22 | ||
| cache: npm | ||
| cache-dependency-path: wrapper-frontend/package-lock.json | ||
|
|
||
| - run: npm ci | ||
|
|
||
| - run: npm run lint | ||
|
|
||
| - run: npm run format:check | ||
|
|
||
| - run: npm run check | ||
|
|
||
| - run: npm run build |
This file contains hidden or 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,5 +1,8 @@ | ||
| image: ubuntu:latest | ||
|
|
||
| variables: | ||
| GIT_SUBMODULE_STRATEGY: recursive | ||
|
|
||
| stages: | ||
| - build | ||
|
|
||
|
|
||
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| [submodule "proto"] | ||
| path = proto | ||
| url = https://github.com/RoboCup-SSL/ssl-protocol-defs.git | ||
| branch = main |
This file contains hidden or 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 hidden or 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,91 @@ | ||
| { | ||
| description = "SSL vision_processor build environment"; | ||
|
|
||
| inputs = { | ||
| nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; | ||
| }; | ||
|
|
||
| outputs = | ||
| { self, nixpkgs }: | ||
| let | ||
| inherit (nixpkgs) lib; | ||
| systems = [ "x86_64-linux" "aarch64-linux" ]; | ||
| forAllSystems = lib.genAttrs systems; | ||
| in | ||
| { | ||
| devShells = forAllSystems ( | ||
| system: | ||
| let | ||
| pkgs = nixpkgs.legacyPackages.${system}; | ||
|
|
||
| # Only what python/*.py needs at the system level. wrapper_backend/ is | ||
| # uv-managed (see pyproject.toml) and brings its own venv. | ||
| python = pkgs.python3.withPackages (ps: [ | ||
| ps.protobuf | ||
| ps.pyyaml | ||
| ps.opencv4 # python/cam_viewer.py | ||
| ]); | ||
|
|
||
| # pocl is a CPU OpenCL runtime. It makes the build environment | ||
| # self-contained and testable without a GPU driver; a real GPU ICD on | ||
| # the host is picked up instead when OCL_ICD_VENDORS points at it. | ||
| openclRuntime = pkgs.pocl; | ||
| in | ||
| { | ||
| default = pkgs.mkShell { | ||
| nativeBuildInputs = with pkgs; [ | ||
| cmake | ||
| pkg-config | ||
| protobuf # provides protoc for both C++ and Python codegen | ||
| ]; | ||
|
|
||
| buildInputs = with pkgs; [ | ||
| # Deliberately the nixpkgs default (3.4.x), matching what every | ||
| # distro ships: Debian, Ubuntu through 26.04 LTS, and Fedora are | ||
| # all still on 3.4. Pinning eigen_5 here would let code compile | ||
| # that does not build for anyone packaging against a distro Eigen. | ||
| eigen | ||
|
|
||
| opencv # core imgproc imgcodecs videoio | ||
| yaml-cpp | ||
| # Must match the ffmpeg nixpkgs built opencv against, currently | ||
| # 8.1.2. The default `ffmpeg` is 9.x, which links fine but loads a | ||
| # second set of libav* sonames alongside the ones opencv's videoio | ||
| # pulls in -- two copies of ffmpeg's global state in one process. | ||
| ffmpeg_8 # libavformat libavcodec libavutil | ||
| protobuf | ||
|
|
||
| opencl-headers # CL/cl.h | ||
| opencl-clhpp # CL/opencl.hpp (CL_HPP_TARGET_OPENCL_VERSION=300) | ||
| ocl-icd # libOpenCL.so, the ICD loader | ||
| openclRuntime | ||
|
|
||
| python | ||
| uv # wrapper_backend/ | ||
| ]; | ||
|
|
||
| # The ICD loader finds runtimes through this. Without it the loader | ||
| # reports zero platforms and vision_processor exits at startup. | ||
| OCL_ICD_VENDORS = "${openclRuntime}/etc/OpenCL/vendors"; | ||
|
|
||
| # uv must not download its own interpreter inside the shell. | ||
| UV_PYTHON = python.interpreter; | ||
| UV_PYTHON_DOWNLOADS = "never"; | ||
|
|
||
| shellHook = '' | ||
| echo "vision_processor dev shell" | ||
| echo " eigen ${pkgs.eigen.version}" | ||
| echo " opencv ${pkgs.opencv.version}" | ||
| echo " ffmpeg ${pkgs.ffmpeg_8.version}" | ||
| echo " protobuf ${pkgs.protobuf.version}" | ||
| echo | ||
| echo " cmake -B build . && make -C build -j vision_processor" | ||
| echo | ||
| echo "Camera SDKs (Spinnaker, mvIMPACT) are proprietary and not" | ||
| echo "packaged here; the OpenCV backend is available." | ||
| ''; | ||
| }; | ||
| } | ||
| ); | ||
| }; | ||
| } |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the merge conflicts, config missing :D