Skip to content

Add C++ autodiff example to README and CI workflow#2

Merged
alexdummer merged 1 commit into
mainfrom
copilot/add-cpp-example
Apr 1, 2026
Merged

Add C++ autodiff example to README and CI workflow#2
alexdummer merged 1 commit into
mainfrom
copilot/add-cpp-example

Conversation

Copilot AI commented Apr 1, 2026

Copy link
Copy Markdown
Contributor

Summary

Integrates the existing C++ autodiff example (already present in cpp/autodiff/) fully into the repository by updating documentation and CI.

Changes

README.md

  • Split the Tools section into Python and C++ subsections, adding the autodiff C++ library to the table.
  • Split Setup and Usage into Python and C++ subsections with clear per-language instructions.
  • C++ setup covers installing Eigen3 (apt / Homebrew) and copying the header-only autodiff library.

cpp/autodiff/build_and_run_example.sh

  • Uses pkg-config --cflags eigen3 to automatically resolve the Eigen3 include path, making the script work cross-platform without hard-coded paths.

.github/workflows/run-examples.yml

  • Adds a new run-cpp-example job that:
    1. Installs libeigen3-dev via apt.
    2. Clones the autodiff header-only library at tag v1.1.2 and copies headers to /usr/local/include/.
    3. Builds and runs the example via build_and_run_example.sh.

Copilot AI requested a review from alexdummer April 1, 2026 20:40
@alexdummer alexdummer marked this pull request as ready for review April 1, 2026 23:08
@alexdummer alexdummer merged commit c21b58e into main Apr 1, 2026
6 checks passed
@alexdummer alexdummer deleted the copilot/add-cpp-example branch May 1, 2026 14:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants