Skip to content

Commit

Permalink
update paths for example artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
jakebolewski committed Dec 1, 2021
1 parent d6be4d7 commit a198aef
Show file tree
Hide file tree
Showing 14 changed files with 64 additions and 17 deletions.
5 changes: 4 additions & 1 deletion examples/bickleyjet/bickleyjet_cg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -145,4 +145,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/energy.png", "Total Energy")
linkfig(
relpath(joinpath(path, "energy.png"), joinpath(@__DIR__, "../..")),
"Total Energy",
)
5 changes: 4 additions & 1 deletion examples/bickleyjet/bickleyjet_cg_invariant_hypervisc.jl
Original file line number Diff line number Diff line change
Expand Up @@ -146,4 +146,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/energy.png", "Total Energy")
linkfig(
relpath(joinpath(path, "energy.png"), joinpath(@__DIR__, "../..")),
"Total Energy",
)
9 changes: 6 additions & 3 deletions examples/bickleyjet/bickleyjet_cg_unsmesh.jl
Original file line number Diff line number Diff line change
Expand Up @@ -131,10 +131,10 @@ mkpath(path)
anim = Plots.@animate for u in sol.u
Plots.plot(u.ρθ, clim = (-1, 1))
end
Plots.mp4(anim, joinpath(path, "tracer_uns2dmesh.mp4"), fps = 10)
Plots.mp4(anim, joinpath(path, "tracer.mp4"), fps = 10)

Es = [total_energy(u, parameters) for u in sol.u]
Plots.png(Plots.plot(Es), joinpath(path, "energy_uns2dmesh.png"))
Plots.png(Plots.plot(Es), joinpath(path, "energy.png"))


function linkfig(figpath, alt = "")
Expand All @@ -146,4 +146,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/energy_uns2dmesh.png", "Total Energy")
linkfig(
relpath(joinpath(path, "energy.png"), joinpath(@__DIR__, "../..")),
"Total Energy",
)
5 changes: 4 additions & 1 deletion examples/bickleyjet/bickleyjet_dg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -250,4 +250,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/energy.png", "Total Energy")
linkfig(
relpath(joinpath(path, "energy.png"), joinpath(@__DIR__, "../..")),
"Total Energy",
)
5 changes: 4 additions & 1 deletion examples/column/advect.jl
Original file line number Diff line number Diff line change
Expand Up @@ -209,4 +209,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/advect_end.png", "Advect End Simulation")
linkfig(
relpath(joinpath(path, "advect_end.png"), joinpath(@__DIR__, "../..")),
"Advect End Simulation",
)
5 changes: 4 additions & 1 deletion examples/column/advect_diffusion.jl
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,9 @@ function linkfig(figpath, alt = "")
end

linkfig(
"output/$(dirname)/advect_diffusion_end.png",
relpath(
joinpath(path, "advect_diffusion_end.png"),
joinpath(@__DIR__, "../.."),
),
"Advection-Diffusion End Simulation",
)
5 changes: 4 additions & 1 deletion examples/column/ekman.jl
Original file line number Diff line number Diff line change
Expand Up @@ -191,4 +191,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/ekman_end.png", "ekman End")
linkfig(
relpath(joinpath(path, "ekman_end.png"), joinpath(@__DIR__, "../..")),
"Ekman End",
)
5 changes: 4 additions & 1 deletion examples/column/heat.jl
Original file line number Diff line number Diff line change
Expand Up @@ -86,4 +86,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/heat_end.png", "Heat End Simulation")
linkfig(
relpath(joinpath(path, "heat_end.png"), joinpath(@__DIR__, "../..")),
"Heat End Simulation",
)
5 changes: 4 additions & 1 deletion examples/column/hydrostatic.jl
Original file line number Diff line number Diff line change
Expand Up @@ -209,4 +209,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/hydrostatic_end.png", "Hydrostatic End")
linkfig(
"examples/column/output/$(dirname)/hydrostatic_end.png",
"Hydrostatic End",
)
8 changes: 7 additions & 1 deletion examples/column/hydrostatic_ekman.jl
Original file line number Diff line number Diff line change
Expand Up @@ -257,4 +257,10 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/hydrostatic_ekman_end.png", "ekman end")
linkfig(
relpath(
joinpath(path, "hydrostatic_ekman_end.png"),
joinpath(@__DIR__, "../.."),
),
"ekman end",
)
5 changes: 4 additions & 1 deletion examples/column/hydrostatic_implicit.jl
Original file line number Diff line number Diff line change
Expand Up @@ -324,4 +324,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/hydrostatic_end.png", "Hydrostatic End")
linkfig(
relpath(joinpath(path, "hydrostatic_end.png"), joinpath(@__DIR__, "../..")),
"Hydrostatic End",
)
10 changes: 9 additions & 1 deletion examples/column/step.jl
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,14 @@ function linkfig(figpath, alt = "")
end

linkfig(
"output/$(dirname)/advect_step_function_end.png",
"examples/column/output/$(dirname)/advect_step_function_end.png",
"Advect End Simulation",
)

linkfig(
relpath(
joinpath(path, "advect_step_function_end.png"),
joinpath(@__DIR__, "../.."),
),
"Advect End Simulation",
)
5 changes: 4 additions & 1 deletion examples/column/wave.jl
Original file line number Diff line number Diff line change
Expand Up @@ -96,4 +96,7 @@ function linkfig(figpath, alt = "")
end
end

linkfig("output/$(dirname)/wave_end.png", "Wave End")
linkfig(
relpath(joinpath(path, "wave_end.png"), joinpath(@__DIR__, "../..")),
"Wave End",
)
4 changes: 2 additions & 2 deletions examples/hybrid/bubble.jl
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ function rhs!(dY, Y, _, t)
Yfρ = @. If(Yc.ρ)

### HYPERVISCOSITY
# 1) compute hyperviscosity coefficients
# 1) compute hyperviscosity coefficients
@. dYc.ρθ = hdiv(hgrad(θ))
@. dYc.ρuₕ = hdiv(hgrad(uₕ))
@. dρw = hdiv(hgrad(w))
Expand Down Expand Up @@ -245,7 +245,7 @@ function rhs!(dY, Y, _, t)
uₕf = @. If(Yc.ρuₕ / Yc.ρ) # requires boundary conditions
@. dρw -= hdiv(uₕf ρw)

### UPWIND FLUX CORRECTION
### UPWIND FLUX CORRECTION
upwind_correction = true
if upwind_correction
@. dYc.ρ += fcc(w, Yc.ρ)
Expand Down

0 comments on commit a198aef

Please sign in to comment.