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

Fix IntervalArithmetic version because of bug with DelaunayTriangulation #3595

Merged
merged 1 commit into from
Feb 4, 2024

Conversation

jkrumbiegel
Copy link
Member

Started getting this error since yesterday on CI, related to JuliaIntervals/IntervalArithmetic.jl#613 which was tagged yesterday. I don't know anything about the underlying logic so I can only pin for now.

The error:

2024-02-03T17:39:00.9673978Z ┌ Franklin Warning: in <reference/plots/tricontourf.md>
2024-02-03T17:39:00.9845503Z │ There was an error of type 'ArgumentError' when running a code block.
2024-02-03T17:39:00.9847835Z │ Checking the output files '/home/runner/work/Makie.jl/Makie.jl/docs/__site/assets/reference/plots/tricontourf/code/output/example_480fd0da.(out|res)'
2024-02-03T17:39:00.9849867Z │ might be helpful to understand and solve the issue.
2024-02-03T17:39:00.9850690Z │ 
2024-02-03T17:39:00.9851170Z │ Relevant pointers:
2024-02-03T17:39:00.9852086Z │ - evaluation of Julia code blocks: https://franklinjl.org/code/
2024-02-03T17:39:00.9852896Z │ 
2024-02-03T17:39:00.9853321Z │ Details:
2024-02-03T17:39:00.9854126Z │ ArgumentError: `==` is only supported between thin intervals and numbers
2024-02-03T17:39:00.9855036Z │ Stacktrace:
2024-02-03T17:39:00.9855621Z │   [1] ==
2024-02-03T17:39:00.9857147Z │     @ ~/.julia/packages/IntervalArithmetic/rX8mD/src/intervals/real_interface.jl:149 [inlined]
2024-02-03T17:39:00.9858370Z │   [2] ==
2024-02-03T17:39:00.9859352Z │     @ ~/.julia/packages/IntervalArithmetic/rX8mD/src/intervals/real_interface.jl:155 [inlined]
2024-02-03T17:39:00.9861583Z │   [3] incircle_slow(p::Tuple{Float64, Float64}, q::Tuple{Float64, Float64}, r::Tuple{Float64, Float64}, a::Tuple{Float64, Float64})
2024-02-03T17:39:00.9863708Z │     @ ExactPredicates ~/.julia/packages/ExactPredicates/p3E85/src/Codegen.jl:340
2024-02-03T17:39:00.9864793Z │   [4] incircle
2024-02-03T17:39:00.9865844Z │     @ ~/.julia/packages/ExactPredicates/p3E85/src/Codegen.jl:470 [inlined]
2024-02-03T17:39:00.9867921Z │   [5] incircle_predicate(a::Tuple{Float64, Float64}, b::Tuple{Float64, Float64}, c::Tuple{Float64, Float64}, p::Tuple{Float64, Float64})
2024-02-03T17:39:00.9870120Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/predicates/general.jl:37
2024-02-03T17:39:00.9871621Z │   [6] point_position_relative_to_circle
2024-02-03T17:39:00.9873072Z │     @ ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/predicates/general.jl:142 [inlined]
2024-02-03T17:39:00.9876951Z │   [7] point_position_relative_to_circumcircle(i::Int64, j::Int64, k::Int64, ℓ::Int64, pts::Matrix{Float64}, representative_point_list::Dict{Int64, DelaunayTriangulation.RepresentativeCoordinates{Int64, Float64}}, boundary_map::OrderedCollections.OrderedDict{Int64, Vector{Int64}})
2024-02-03T17:39:00.9880502Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/predicates/index_and_ghost_handling.jl:61
2024-02-03T17:39:00.9882323Z │   [8] point_position_relative_to_circumcircle
2024-02-03T17:39:00.9884099Z │     @ ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/data_structures/triangulation/predicates.jl:45 [inlined]
2024-02-03T17:39:00.9890482Z │   [9] dig_cavity!(tri::DelaunayTriangulation.Triangulation{Matrix{Float64}, Set{Tuple{Int64, Int64, Int64}}, Int64, Tuple{Int64, Int64}, Set{Tuple{Int64, Int64}}, Vector{Int64}, Dict{Tuple{Int64, Int64}, Tuple{Vector{Int64}, Int64}}, OrderedCollections.OrderedDict{Int64, Vector{Int64}}, OrderedCollections.OrderedDict{Int64, UnitRange{Int64}}, Dict{Int64, DelaunayTriangulation.RepresentativeCoordinates{Int64, Float64}}}, r::Int64, i::Int64, j::Int64, ℓ::Int64, flag::DelaunayTriangulation.Certificate.T, V::Tuple{Int64, Int64, Int64}, store_event_history::Val{false}, event_history::Nothing, peek::Val{false})
2024-02-03T17:39:00.9896371Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:329 [inlined]
2024-02-03T17:39:00.9903466Z │  [10] add_point_bowyer_watson_dig_cavities!(tri::DelaunayTriangulation.Triangulation{Matrix{Float64}, Set{Tuple{Int64, Int64, Int64}}, Int64, Tuple{Int64, Int64}, Set{Tuple{Int64, Int64}}, Vector{Int64}, Dict{Tuple{Int64, Int64}, Tuple{Vector{Int64}, Int64}}, OrderedCollections.OrderedDict{Int64, Vector{Int64}}, OrderedCollections.OrderedDict{Int64, UnitRange{Int64}}, Dict{Int64, DelaunayTriangulation.RepresentativeCoordinates{Int64, Float64}}}, new_point::Int64, V::Tuple{Int64, Int64, Int64}, q::Tuple{Float64, Float64}, flag::DelaunayTriangulation.Certificate.T, update_representative_point::Bool, store_event_history::Val{false}, event_history::Nothing, peek::Val{false})
2024-02-03T17:39:00.9909748Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:268
2024-02-03T17:39:00.9917222Z │  [11] add_point_bowyer_watson_after_found_triangle!(tri::DelaunayTriangulation.Triangulation{Matrix{Float64}, Set{Tuple{Int64, Int64, Int64}}, Int64, Tuple{Int64, Int64}, Set{Tuple{Int64, Int64}}, Vector{Int64}, Dict{Tuple{Int64, Int64}, Tuple{Vector{Int64}, Int64}}, OrderedCollections.OrderedDict{Int64, Vector{Int64}}, OrderedCollections.OrderedDict{Int64, UnitRange{Int64}}, Dict{Int64, DelaunayTriangulation.RepresentativeCoordinates{Int64, Float64}}}, new_point::Int64, V::Tuple{Int64, Int64, Int64}, q::Tuple{Float64, Float64}, flag::DelaunayTriangulation.Certificate.T, update_representative_point::Bool, store_event_history::Val{false}, event_history::Nothing, peek::Val{false})
2024-02-03T17:39:00.9923631Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:247
2024-02-03T17:39:00.9925364Z │  [12] add_point_bowyer_watson_and_process_after_found_triangle!
2024-02-03T17:39:00.9927053Z │     @ ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:154 [inlined]
2024-02-03T17:39:00.9933059Z │  [13] add_point_bowyer_watson!(tri::DelaunayTriangulation.Triangulation{Matrix{Float64}, Set{Tuple{Int64, Int64, Int64}}, Int64, Tuple{Int64, Int64}, Set{Tuple{Int64, Int64}}, Vector{Int64}, Dict{Tuple{Int64, Int64}, Tuple{Vector{Int64}, Int64}}, OrderedCollections.OrderedDict{Int64, Vector{Int64}}, OrderedCollections.OrderedDict{Int64, UnitRange{Int64}}, Dict{Int64, DelaunayTriangulation.RepresentativeCoordinates{Int64, Float64}}}, new_point::Int64, initial_search_point::Int64, rng::TaskLocalRNG, update_representative_point::Bool, store_event_history::Val{false}, event_history::Nothing, exterior_curve_index::Int64, peek::Val{false})
2024-02-03T17:39:00.9939065Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:175
2024-02-03T17:39:00.9945766Z │  [14] add_point_bowyer_watson!(tri::DelaunayTriangulation.Triangulation{Matrix{Float64}, Set{Tuple{Int64, Int64, Int64}}, Int64, Tuple{Int64, Int64}, Set{Tuple{Int64, Int64}}, Vector{Int64}, Dict{Tuple{Int64, Int64}, Tuple{Vector{Int64}, Int64}}, OrderedCollections.OrderedDict{Int64, Vector{Int64}}, OrderedCollections.OrderedDict{Int64, UnitRange{Int64}}, Dict{Int64, DelaunayTriangulation.RepresentativeCoordinates{Int64, Float64}}}, new_point::Int64, initial_search_point::Int64, rng::TaskLocalRNG, update_representative_point::Bool, store_event_history::Val{false}, event_history::Nothing, exterior_curve_index::Int64, peek::Val{false})
2024-02-03T17:39:00.9951825Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:169 [inlined]
2024-02-03T17:39:00.9959124Z │  [15] _triangulate_bowyer_watson!(tri::DelaunayTriangulation.Triangulation{Matrix{Float64}, Set{Tuple{Int64, Int64, Int64}}, Int64, Tuple{Int64, Int64}, Set{Tuple{Int64, Int64}}, Vector{Int64}, Dict{Tuple{Int64, Int64}, Tuple{Vector{Int64}, Int64}}, OrderedCollections.OrderedDict{Int64, Vector{Int64}}, OrderedCollections.OrderedDict{Int64, UnitRange{Int64}}, Dict{Int64, DelaunayTriangulation.RepresentativeCoordinates{Int64, Float64}}}, point_order::Vector{Int64}, num_sample_rule::typeof(DelaunayTriangulation.default_num_samples), delete_ghosts::Bool, delete_empty_features::Bool, try_last_inserted_point::Bool, rng::TaskLocalRNG, recompute_representative_point::Bool)
2024-02-03T17:39:00.9965375Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:130
2024-02-03T17:39:00.9971296Z │  [16] triangulate_bowyer_watson(points::Matrix{Float64}; IntegerType::Type{Int64}, EdgeType::Type{Tuple{Int64, Int64}}, TriangleType::Type{Tuple{Int64, Int64, Int64}}, EdgesType::Type{Set{Tuple{Int64, Int64}}}, TrianglesType::Type{Set{Tuple{Int64, Int64, Int64}}}, randomise::Bool, delete_ghosts::Bool, delete_empty_features::Bool, try_last_inserted_point::Bool, skip_points::Set{Int64}, num_sample_rule::typeof(DelaunayTriangulation.default_num_samples), rng::TaskLocalRNG, point_order::Vector{Int64}, recompute_representative_point::Bool)
2024-02-03T17:39:00.9976582Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/bowyer_watson.jl:94
2024-02-03T17:39:00.9982779Z │  [17] triangulate(points::Matrix{Float64}; edges::Nothing, boundary_nodes::Nothing, IntegerType::Type{Int64}, EdgeType::Type{Tuple{Int64, Int64}}, TriangleType::Type{Tuple{Int64, Int64, Int64}}, EdgesType::Type{Set{Tuple{Int64, Int64}}}, TrianglesType::Type{Set{Tuple{Int64, Int64, Int64}}}, randomise::Bool, delete_ghosts::Bool, delete_empty_features::Bool, try_last_inserted_point::Bool, skip_points::Set{Int64}, num_sample_rule::typeof(DelaunayTriangulation.default_num_samples), rng::TaskLocalRNG, point_order::Vector{Int64}, recompute_representative_point::Bool, delete_holes::Bool, check_arguments::Bool)
2024-02-03T17:39:00.9988251Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/triangulate.jl:70
2024-02-03T17:39:00.9989862Z │  [18] triangulate(points::Matrix{Float64})
2024-02-03T17:39:00.9991417Z │     @ DelaunayTriangulation ~/.julia/packages/DelaunayTriangulation/ZXK1v/src/triangulation/triangulate.jl:51
2024-02-03T17:39:00.9992801Z │  [19] #convert_arguments#792
2024-02-03T17:39:00.9993957Z │     @ Makie ~/work/Makie.jl/Makie.jl/src/basic_recipes/tricontourf.jl:62 [inlined]
2024-02-03T17:39:00.9996161Z │  [20] (Plot{Makie.tricontourf})(args::Tuple{Vector{Float64}, Vector{Float64}, Vector{Float64}}, plot_attributes::Dict{Symbol, Any})
2024-02-03T17:39:00.9997791Z │     @ Makie ~/work/Makie.jl/Makie.jl/src/interfaces.jl:142
2024-02-03T17:39:00.9999055Z │  [21] _create_plot(::Function, ::Dict{Symbol, Any}, ::GridPosition, ::Vararg{Any})
2024-02-03T17:39:01.0000449Z │     @ Makie ~/work/Makie.jl/Makie.jl/src/figureplotting.jl:248
2024-02-03T17:39:01.0002520Z │  [22] tricontourf(::GridPosition, ::Vararg{Any}; kw::@Kwargs{triangulation::Makie.DelaunayTriangulation, axis::@NamedTuple{aspect::Int64, title::String}})
2024-02-03T17:39:01.0004430Z │     @ Makie ~/work/Makie.jl/Makie.jl/MakieCore/src/recipes.jl:175
2024-02-03T17:39:01.0005309Z └
2024-02-03T17:39:01.0005958Z ┌ Franklin Warning: in <tricontourf.md>
2024-02-03T17:39:01.0007168Z │ Encountered an issue processing 'tricontourf.md' in docs/reference/plots.
2024-02-03T17:39:01.0008376Z │ Verify, then re-start the Franklin server.
2024-02-03T17:39:01.0009228Z │ The error is displayed below:
2024-02-03T17:39:01.0010265Z │ ErrorException("`fail_on_warning` is true, so exiting with error")

@MakieBot
Copy link
Collaborator

MakieBot commented Feb 4, 2024

Compile Times benchmark

Note, that these numbers may fluctuate on the CI servers, so take them with a grain of salt. All benchmark results are based on the mean time and negative percent mean faster than the base branch. Note, that GLMakie + WGLMakie run on an emulated GPU, so the runtime benchmark is much slower. Results are from running:

using_time = @ctime using Backend
# Compile time
create_time = @ctime fig = scatter(1:4; color=1:4, colormap=:turbo, markersize=20, visible=true)
display_time = @ctime Makie.colorbuffer(display(fig))
# Runtime
create_time = @benchmark fig = scatter(1:4; color=1:4, colormap=:turbo, markersize=20, visible=true)
display_time = @benchmark Makie.colorbuffer(fig)
using create display create display
GLMakie 3.56s (3.42, 3.70) 0.11+- 435.36ms (394.36, 463.70) 24.80+- 497.35ms (471.36, 533.62) 22.38+- 7.65ms (7.36, 8.00) 0.23+- 26.12ms (25.57, 26.37) 0.29+-
master 3.63s (3.53, 3.71) 0.06+- 429.91ms (393.13, 453.41) 20.86+- 496.75ms (477.67, 510.28) 12.17+- 7.76ms (7.43, 8.16) 0.26+- 26.15ms (25.58, 26.43) 0.33+-
evaluation 1.02x invariant, -0.07s (-0.77d, 0.18p, 0.08std) 0.99x invariant, 5.44ms (0.24d, 0.66p, 22.83std) 1.00x invariant, 0.61ms (0.03d, 0.95p, 17.27std) 1.02x invariant, -0.12ms (-0.48d, 0.39p, 0.24std) 1.00x invariant, -0.04ms (-0.12d, 0.83p, 0.31std)
CairoMakie 3.11s (3.07, 3.16) 0.03+- 327.53ms (323.59, 335.48) 3.84+- 142.02ms (140.61, 143.63) 1.22+- 7.35ms (7.26, 7.48) 0.09+- 602.37μs (600.08, 605.98) 1.94+-
master 3.07s (3.05, 3.10) 0.02+- 324.97ms (321.65, 330.14) 3.32+- 142.84ms (140.28, 146.08) 1.73+- 7.47ms (7.24, 7.77) 0.16+- 607.76μs (603.00, 613.68) 3.43+-
evaluation 0.99x slower X, 0.04s (1.72d, 0.01p, 0.03std) 0.99x invariant, 2.55ms (0.71d, 0.21p, 3.58std) 1.01x invariant, -0.82ms (-0.55d, 0.33p, 1.48std) 1.02x invariant, -0.13ms (-0.97d, 0.10p, 0.12std) 1.01x faster ✓, -5.39μs (-1.94d, 0.01p, 2.68std)
WGLMakie 3.72s (3.61, 3.83) 0.09+- 324.37ms (306.25, 345.59) 13.82+- 8.84s (8.68, 9.16) 0.17+- 9.14ms (8.95, 9.40) 0.17+- 72.77ms (67.70, 78.51) 4.68+-
master 3.64s (3.60, 3.74) 0.05+- 320.92ms (312.96, 338.05) 8.65+- 8.88s (8.65, 9.09) 0.15+- 9.07ms (8.79, 9.71) 0.31+- 75.94ms (67.61, 92.04) 8.49+-
evaluation 0.98x invariant, 0.08s (1.08d, 0.07p, 0.07std) 0.99x invariant, 3.45ms (0.30d, 0.59p, 11.24std) 1.00x invariant, -0.04s (-0.25d, 0.65p, 0.16std) 0.99x invariant, 0.07ms (0.30d, 0.59p, 0.24std) 1.04x invariant, -3.17ms (-0.46d, 0.41p, 6.58std)

@jkrumbiegel jkrumbiegel merged commit a007584 into master Feb 4, 2024
17 checks passed
@jkrumbiegel jkrumbiegel deleted the jk/fix-interval-arithmetic-version branch February 4, 2024 10:02
@DanielVandH
Copy link
Contributor

Should be fixed now thanks to lairez/ExactPredicates.jl#25 and JuliaIntervals/IntervalArithmetic.jl#625

@OlivierHnt
Copy link

IntervalArithmetic v0.22.7 has just been released which fixes the issue introduced in 0.22.6.
If you want, you can go back to using "0.22" for the compat entry.

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.

4 participants