Docs overhaul + cleanup & coverage (rebased on master)#92
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #92 +/- ##
===========================================
+ Coverage 11.79% 80.82% +69.02%
===========================================
Files 18 13 -5
Lines 2594 292 -2302
===========================================
- Hits 306 236 -70
+ Misses 2288 56 -2232 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Base automatically changed from
vs/cxxwrap-compat-017
to
vs/value-vector-conversion
June 5, 2026 20:47
…doctest
The package shipped zero docstrings, and the (channels, cols, rows) Mat memory
layout — the convention that made the features2d descriptor test wrong — was
undocumented. Add:
- A Mat docstring explaining the (channels, cols, rows) axis order with the
descriptor-matrix consequence (keypoint axis is dim 3), plus a jldoctest so the
existing (previously no-op) doctest CI job tests something real.
- Docstrings on Vec, fileio load/save, and imdecode(::AbstractVector{UInt8}).
- A module-level OpenCV docstring pointing at the layout and gen/funclist.csv.
- A 'Memory layout' note in the Getting Started docs page.
Verified: doctest(OpenCV) passes (1 doctest); suite 230/230.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The docstrings added earlier rendered only via a raw `@autodocs` dump at the bottom of the landing page, and there was no narrative reference for the package's conventions. Restructure the manual into real pages: - Core concepts (new): the cv:: -> OpenCV. naming map, the (channels, cols, rows) Mat layout, supported dtypes, Julia-array interop, scalars and geometry types. - API reference (new): @docs blocks for the hand-written surface (module, Mat, Vec, the geometry primitives, load/save/imdecode), replacing the index autodocs. - index.md: trimmed to a real landing page — install, quick start, the layout callout, and a Manual table of contents. - Docstrings for the geometry primitives in typestructs.jl (Point, Point3, Size, Rect, RotatedRect, Range, TermCriteria, cvComplex). - make.jl: register the new pages; checkdocs=:exports. Verified locally: full `makedocs` build is clean (no broken @refs, no missing docs) and the doctest passes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…e 50%->80%
Medium-value:
- Replace the two parallel 7-branch depth<->dtype if/elseif ladders in
mat_conversion.jl with one bijective _CV_DEPTH table + _cv_depth/_julia_eltype
helpers; adding a dtype is now one entry.
- julia_to_cpp(::InputArray) no longer falls through to a silent `return nothing`
on an unsupported eltype -- it throws OpenCVError.
- Repoint the README wrapped-methods link to the vendored gen/funclist.csv.
Low-value:
- Split cv_manual_wrap.jl by concern into src/overrides/{defaults,covariance,
convenience}.jl.
- Add an OpenCVError exception type (used at the mat_conversion error sites);
raw cv::Exceptions still surface as ErrorException until the generator wraps
them (noted).
Coverage push (src/, excluding generated): 50.3% -> 79.8%. New test_core_types.jl
and test_conversions.jl plus fileio/objdetect additions cover the Mat/Vec
AbstractArray interface, all 7 cv::Mat dtypes, Scalar tuples of every arity,
typestructs, OpenCVError, the scalar identity/Tuple/Bool conversions, FileIO
Stream + flags/params, show(MIME image/png), and CascadeClassifier empty().
codecov.yml now ignores src/generated/.
Two latent bugs surfaced and fixed by the new fileio coverage:
- load(::Stream) called bare `read` (the generated cv::read wrappers shadow
Base.read inside the module) -- now Base.read.
- load(::Stream) reshaped to 3D and called a 1-arg imdecode that never existed --
now uses the imdecode(::AbstractVector{UInt8}) convenience method (#58).
Suite: 310/310.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
5e61e0f to
ccfb63e
Compare
The README had grown to duplicate the documentation site (version-query snippet, getting-started, the Mandrill usage example, versioning prose). Cut those — they live in the docs now — and keep the README focused on what only belongs at the repo root: a one-paragraph description, a prominent docs link, installation, and contributor/developer info (local dev, the three-layer architecture). Also refresh the src/ file list (src/overrides/, errors.jl; cv_manual_wrap.jl was split).
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Rebased onto
masteras a single linear PR. Combines the documentation work with the cleanup/coverage work that had been merged into this branch (former #93), dropping the intermediate merge commits.Documentation
cv::→OpenCV.naming, the(channels, cols, rows)Matlayout, dtypes, Julia-array interop, scalars/geometry.@docsfor the module,Mat,Vec, the geometry primitives, andload/save/imdecode(replaces the raw@autodocsdump on the landing page).index.md(install, quick-start, layout callout, manual ToC — merged with Expand README and docs to address #3 #86's version/versioning sections), docstrings onMat/Vec/fileio/geometry types, a realjldoctest.Cleanup & coverage
_CV_DEPTHtable);OpenCVError; splitcv_manual_wrap.jlintosrc/overrides/;julia_to_cppthrows instead of silentnothing.src/raised 50% → 80% (newtest_core_types.jl/test_conversions.jl+ fileio/objdetect additions);codecov.ymlignoressrc/generated/.load(::Stream)bugs found by the new coverage (shadowedread, non-existent 1-argimdecode).Verified on the rebased branch: full suite 310/310,
makedocsbuilds clean (no broken refs / missing docs, doctest passes).🤖 Generated with Claude Code