Skip to content

Commit

Permalink
Make devops work
Browse files Browse the repository at this point in the history
  • Loading branch information
VarLad committed May 21, 2024
1 parent f9928f0 commit e42a46f
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 3 deletions.
5 changes: 5 additions & 0 deletions ext/MakieExt/bench.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,20 @@ function PerfChecker.checkres_to_scatterlines(
f = Figure()
ax = f[1,1] = Axis(f)
colors = make_colors(length(props))
max = 2
for i in eachindex(data[1])
xs = collect(eachindex(versionnums))
ys = d[i] ./ r[i]
if max < maximum(ys)
max = maximum(ys)
end
scatterlines!(xs, ys, label=string(props[i]), color = (colors[i], 0.4))
end
ax.xticks = (eachindex(versionnums), string.(versionnums))
ax.xlabel = "versions"
ax.ylabel = "ratio"
ax.title = "Evolution for $(x.pkgs[1].name) (via BenchmarkTools.jl)"
ylims!(;low=0,high=max)
axislegend()
return f
end
Expand Down
6 changes: 5 additions & 1 deletion ext/MakieExt/chair.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,24 @@ function PerfChecker.checkres_to_scatterlines(
f = Figure()
ax = f[1,1] = Axis(f)
colors = make_colors(length(props))
max = 2
for i in eachindex(data[1])
xs = collect(eachindex(versionnums))
ys = d[i] ./ r[i]
if max < maximum(ys)
max = maximum(ys)
end
scatterlines!(xs, ys, label=string(props[i]), color = (colors[i], 0.4))
end
ax.xticks = (eachindex(versionnums), string.(versionnums))
ax.xlabel = "versions"
ax.ylabel = "ratio"
ax.title = "Evolution for $(x.pkgs[1].name) (via Chairmarks.jl)"
ylims!(;low=0,high=max)
axislegend()
return f
end


function PerfChecker.checkres_to_boxplots(
x::PerfChecker.CheckerResult, ::Val{:chairmark}; kwarg::Symbol = :times)
di = Dict()
Expand Down
3 changes: 2 additions & 1 deletion perf/PatternFolds/bench.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ using PerfChecker, BenchmarkTools, CairoMakie

d = Dict(:path => @__DIR__, :evals => 1, :samples => 100,
:seconds => 100, :tags => [:patterns, :intervals],
:pkgs => ("PatternFolds", :custom, [v"0.2.2", v"0.2.3"], true))
:pkgs => ("PatternFolds", :custom, [v"0.2.2", v"0.2.3"], true),
:devops => "PatternFolds")

t = @check :benchmark d begin
using PatternFolds
Expand Down
2 changes: 1 addition & 1 deletion perf/PatternFolds/chair.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using PerfChecker, Chairmarks, CairoMakie

d = Dict(:path => @__DIR__, :evals => 1, :tags => [:patterns, :intervals],
:pkgs => ("PatternFolds", :custom, [v"0.2.2", v"0.2.3"], true))
:pkgs => ("PatternFolds", :custom, [v"0.2.2", v"0.2.3"], true), :devops => "PatternFolds")

t = @check :chairmark d begin
using PatternFolds
Expand Down
5 changes: 5 additions & 0 deletions src/check.jl
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,11 @@ function check_function(x::Symbol, d::Dict, block1, block2)
push!(results.tables, res |> to_table)
if !(devop && i == len)
push!(results.pkgs, pkgs[i])
else
pkg = d[:devops]
p = pkg isa Tuple ? pkg[1] : pkg
p = p isa Pkg.PackageSpec ? p.name : p
push!(results.pkgs, Pkg.PackageSpec(name = p, version = "dev"))
end
end

Expand Down

0 comments on commit e42a46f

Please sign in to comment.