Skip to content

Commit

Permalink
Merge #326
Browse files Browse the repository at this point in the history
326: Bugfix darcy plot r=odunbar a=odunbar

<!--- THESE LINES ARE COMMENTED -->
## Purpose 
<!--- One sentence to describe the purpose of this PR, refer to any linked issues:
#14 -- this will link to issue 14
Closes #2 -- this will automatically close issue 2 on PR merge
-->
Closes #325 

## Content
<!---  specific tasks that are currently complete 
- Solution implemented
-->
- variable rename
- [ALSO] docs build error fixed (due to updated Documenter version) by removing `strict=true`

<!---
Review checklist

I have:
- followed the codebase contribution guide: https://clima.github.io/ClimateMachine.jl/latest/Contributing/
- followed the style guide: https://clima.github.io/ClimateMachine.jl/latest/DevDocs/CodeStyle/
- followed the documentation policy: https://github.com/CliMA/policies/wiki/Documentation-Policy
- checked that this PR does not duplicate an open PR.

In the Content, I have included 
- relevant unit tests, and integration tests, 
- appropriate docstrings on all functions, structs, and modules, and included relevant documentation.

-->

----
- [x] I have read and checked the items on the review checklist.


Co-authored-by: odunbar <[email protected]>
  • Loading branch information
bors[bot] and odunbar committed Sep 18, 2023
2 parents 79057eb + c7bbc34 commit 06d68d9
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ makedocs(
pages = pages,
modules = [EnsembleKalmanProcesses],
doctest = true,
strict = true,
clean = true,
checkdocs = :none,
)
Expand Down
Binary file modified docs/src/assets/darcy_final.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/src/assets/darcy_prior.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/src/assets/darcy_true.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions examples/Darcy/darcy.jl
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ println(u_true)
# Now we generate the data sample for the truth in a perfect model setting by evaluating the the model here, and observing it by subsampling in each dimension every `obs_ΔN` points, and add some observational noise
darcy = Setup_Param(pts_per_dim, obs_ΔN, κ_true)
println(" Number of observation points: $(darcy.N_y)")
h_2d = solve_Darcy_2D(darcy, κ_true)
y_noiseless = compute_obs(darcy, h_2d)
h_2d_true = solve_Darcy_2D(darcy, κ_true)
y_noiseless = compute_obs(darcy, h_2d_true)
obs_noise_cov = 0.05^2 * I(length(y_noiseless)) * (maximum(y_noiseless) - minimum(y_noiseless))
truth_sample = vec(y_noiseless + rand(rng, MvNormal(zeros(length(y_noiseless)), obs_noise_cov)))

Expand Down Expand Up @@ -166,7 +166,7 @@ println(get_u_mean_final(ekiobj))
if PLOT_FLAG
gr(size = (1000, 400), legend = false)
p1 = contour(pts_per_dim, pts_per_dim, κ_true', fill = true, levels = 15, title = "kappa true", colorbar = true)
p2 = contour(pts_per_dim, pts_per_dim, h_2d', fill = true, levels = 15, title = "flow true", colorbar = true)
p2 = contour(pts_per_dim, pts_per_dim, h_2d_true', fill = true, levels = 15, title = "flow true", colorbar = true)
l = @layout [a b]
plt = plot(p1, p2, layout = l)
savefig(plt, joinpath(fig_save_directory, "output_true.png"))
Expand Down

0 comments on commit 06d68d9

Please sign in to comment.