Skip to content

Conversation

@mikeingold
Copy link
Collaborator

@mikeingold mikeingold commented Aug 31, 2025

@github-actions
Copy link
Contributor

github-actions bot commented Aug 31, 2025

Benchmark Results (Julia v1.10)

Time benchmarks
main 926e347... main / 926e347...
Differentials/Differential 0.205 ± 0.001 μs 0.212 ± 0.002 μs 0.967 ± 0.01
Differentials/Jacobian 0.171 ± 0.001 μs 0.171 ± 0.0001 μs 1 ± 0.0059
Integrals/Segment/Scalar GaussKronrod 0.631 ± 0.02 μs 0.641 ± 0.02 μs 0.984 ± 0.044
Integrals/Segment/Scalar GaussLegendre 1.71 ± 0.02 μs 1.68 ± 0.01 μs 1.02 ± 0.013
Integrals/Segment/Scalar HAdaptiveCubature 0.852 ± 0.029 μs 0.851 ± 0.021 μs 1 ± 0.042
Integrals/Segment/Vector GaussKronrod 0.662 ± 0.01 μs 0.671 ± 0.01 μs 0.987 ± 0.021
Integrals/Segment/Vector GaussLegendre 4.73 ± 0.26 μs 4.86 ± 0.26 μs 0.973 ± 0.075
Integrals/Segment/Vector HAdaptiveCubature 0.872 ± 0.03 μs 0.872 ± 0.03 μs 1 ± 0.049
Integrals/Sphere/Scalar GaussKronrod 1.13 ± 0.01 μs 1.13 ± 0.02 μs 1 ± 0.02
Integrals/Sphere/Scalar GaussLegendre 1.88 ± 0.0028 ms 1.88 ± 0.0036 ms 0.998 ± 0.0024
Integrals/Sphere/Scalar HAdaptiveCubature 0.048 ± 0.00012 ms 0.0483 ± 9.1e-05 ms 0.994 ± 0.0031
Integrals/Sphere/Vector GaussKronrod 1.16 ± 0.02 μs 1.16 ± 0.011 μs 0.999 ± 0.02
Integrals/Sphere/Vector GaussLegendre 2.05 ± 0.011 ms 2.04 ± 0.014 ms 1 ± 0.0085
Integrals/Sphere/Vector HAdaptiveCubature 0.0495 ± 9.1e-05 ms 0.0495 ± 9e-05 ms 1 ± 0.0026
Rules/GaussLegendre 21.8 ± 0.56 μs 21.5 ± 0.63 μs 1.01 ± 0.04
Specializations/Scalar GaussLegendre/BezierCurve 0.255 ± 0.0074 ms 0.25 ± 0.007 ms 1.02 ± 0.041
Specializations/Scalar GaussLegendre/Line 7.4 ± 0.071 μs 7.29 ± 0.061 μs 1.02 ± 0.013
Specializations/Scalar GaussLegendre/Plane 0.787 ± 0.0017 ms 0.788 ± 0.0013 ms 0.999 ± 0.0028
Specializations/Scalar GaussLegendre/Ray 7.04 ± 0.16 μs 7.11 ± 0.15 μs 0.99 ± 0.031
Specializations/Scalar GaussLegendre/Rope 0.0512 ± 0.00025 ms 0.0517 ± 0.00019 ms 0.992 ± 0.0061
Specializations/Scalar GaussLegendre/Tetrahedron 0.155 ± 0.0014 s 0.154 ± 0.00096 s 1 ± 0.011
Specializations/Scalar GaussLegendre/Triangle 0.699 ± 0.012 ms 0.692 ± 0.012 ms 1.01 ± 0.024
time_to_load 1.5 ± 0.0092 s 1.47 ± 0.0021 s 1.02 ± 0.0064
Memory benchmarks
main 926e347... main / 926e347...
Differentials/Differential 3 allocs: 0.0938 kB 3 allocs: 0.0938 kB 1
Differentials/Jacobian 0 allocs: 0 B 0 allocs: 0 B
Integrals/Segment/Scalar GaussKronrod 2 allocs: 0.0469 kB 2 allocs: 0.0469 kB 1
Integrals/Segment/Scalar GaussLegendre 0 allocs: 0 B 0 allocs: 0 B
Integrals/Segment/Scalar HAdaptiveCubature 7 allocs: 0.492 kB 7 allocs: 0.492 kB 1
Integrals/Segment/Vector GaussKronrod 2 allocs: 0.0781 kB 2 allocs: 0.0781 kB 1
Integrals/Segment/Vector GaussLegendre 0.307 k allocs: 12.8 kB 0.307 k allocs: 12.8 kB 1
Integrals/Segment/Vector HAdaptiveCubature 6 allocs: 0.688 kB 6 allocs: 0.688 kB 1
Integrals/Sphere/Scalar GaussKronrod 2 allocs: 0.0469 kB 2 allocs: 0.0469 kB 1
Integrals/Sphere/Scalar GaussLegendre 0 allocs: 0 B 0 allocs: 0 B
Integrals/Sphere/Scalar HAdaptiveCubature 7 allocs: 0.648 kB 7 allocs: 0.648 kB 1
Integrals/Sphere/Vector GaussKronrod 2 allocs: 0.0781 kB 2 allocs: 0.0781 kB 1
Integrals/Sphere/Vector GaussLegendre 30 k allocs: 1.22 MB 30 k allocs: 1.22 MB 1
Integrals/Sphere/Vector HAdaptiveCubature 6 allocs: 0.812 kB 6 allocs: 0.812 kB 1
Rules/GaussLegendre 7 allocs: 0.0325 MB 7 allocs: 0.0325 MB 1
Specializations/Scalar GaussLegendre/BezierCurve 23 allocs: 0.75 kB 23 allocs: 0.75 kB 1
Specializations/Scalar GaussLegendre/Line 21 allocs: 0.938 kB 21 allocs: 0.938 kB 1
Specializations/Scalar GaussLegendre/Plane 22 allocs: 1.03 kB 22 allocs: 1.03 kB 1
Specializations/Scalar GaussLegendre/Ray 21 allocs: 0.938 kB 21 allocs: 0.938 kB 1
Specializations/Scalar GaussLegendre/Rope 0.068 k allocs: 1.62 kB 0.068 k allocs: 1.62 kB 1
Specializations/Scalar GaussLegendre/Tetrahedron 3 M allocs: 0.179 GB 3 M allocs: 0.179 GB 1
Specializations/Scalar GaussLegendre/Triangle 22 allocs: 1.03 kB 22 allocs: 1.03 kB 1
time_to_load 0.153 k allocs: 14.5 kB 0.153 k allocs: 14.5 kB 1

@codecov
Copy link

codecov bot commented Sep 12, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (23d7d25) to head (926e347).
⚠️ Report is 6 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #201   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           19        19           
  Lines          191       191           
=========================================
  Hits           191       191           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

using Unitful
using Unitful.DefaultSymbols: mm, m


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change

struct Sector{L <: Unitful.Length, A}
r_inner::L
r_outer::L
ϕ_a::A
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change
ϕ_a::A
ϕ_a::A

Comment on lines +36 to +37
function _Ngon(sector::Sector; N=32)
ϕs = range(sector.ϕ_a, sector.ϕ_b, length=N)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change
function _Ngon(sector::Sector; N=32)
ϕs = range(sector.ϕ_a, sector.ϕ_b, length=N)
function _Ngon(sector::Sector; N = 32)
ϕs = range(sector.ϕ_a, sector.ϕ_b, length = N)

return Meshes.Ngon(arc_o..., arc_i...)
end


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change

Comment on lines +57 to +59
Δϕ = 2π/20
ϕas = range(0, 2π - Δϕ, length=20) .- (Δϕ / 2)
ϕbs = range(0, 2π - Δϕ, length=20) .+ (Δϕ / 2)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change
Δϕ = 2π/20
ϕas = range(0, 2π - Δϕ, length=20) .- (Δϕ / 2)
ϕbs = range(0, 2π - Δϕ, length=20) .+ (Δϕ / 2)
Δϕ = 2π / 20
ϕas = range(0, 2π - Δϕ, length = 20) .- (Δϕ / 2)
ϕbs = range(0, 2π - Δϕ, length = 20) .+ (Δϕ / 2)

# To Makie-compatible polygons
_poly(circle::Meshes.Circle; N=32) = [(_Point3f(circle(t)) for t in range(0, 1, length=N))...]
_poly(ngon::Meshes.Ngon) = [(_Point3f(pt) for pt in ngon.vertices)...]
_poly2d(circle::Meshes.Circle; N=32) = [(_Point2f(circle(t)) for t in range(0, 1, length=N))...]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change
_poly2d(circle::Meshes.Circle; N=32) = [(_Point2f(circle(t)) for t in range(0, 1, length=N))...]
function _poly2d(circle::Meshes.Circle; N = 32)
[(_Point2f(circle(t)) for t in range(0, 1, length = N))...]
end

_poly2d(circle::Meshes.Circle; N=32) = [(_Point2f(circle(t)) for t in range(0, 1, length=N))...]
_poly2d(ngon::Meshes.Ngon) = [(_Point2f(pt) for pt in ngon.vertices)...]


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change


# Illustrate the dartboard
fig = Figure()
ax = Axis(fig[1, 1], xlabel="y [m]", ylabel="z [m]")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change
ax = Axis(fig[1, 1], xlabel="y [m]", ylabel="z [m]")
ax = Axis(fig[1, 1], xlabel = "y [m]", ylabel = "z [m]")

Comment on lines +100 to +101
poly!(ax, _poly2d(region.geometry), color=region.color)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change
poly!(ax, _poly2d(region.geometry), color=region.color)
poly!(ax, _poly2d(region.geometry), color = region.color)

# Write score label on geometry
centerPt = centroid(region.geometry)
center = ustrip.(u"m", [centerPt.coords.y, centerPt.coords.z])
text!(ax, string(region.points), position=Point2f(center...), align=(:center,:center), color=:blue, fontsize=10)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[JuliaFormatter] reported by reviewdog 🐶

Suggested change
text!(ax, string(region.points), position=Point2f(center...), align=(:center,:center), color=:blue, fontsize=10)
text!(ax, string(region.points), position = Point2f(center...),
align = (:center, :center), color = :blue, fontsize = 10)

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