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

start of some cleaning of the prob_params stuff #2700

Closed
wants to merge 6 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions Util/scripts/write_probdata.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@
max_step integer 1
small_dt real 1.d-10
xlo_boundary_type character ""
octant logical .false.

This specifies the parameter name, datatype, and default
This specifies the runtime parameter name, datatype, and default
value.

The optional 4th column indicates whether the parameter appears
Expand Down Expand Up @@ -153,7 +152,7 @@ def write_probin(prob_param_files, cxx_prefix):
params = []

print(" ")
print(f"write_probdata.py: creating prob_param C++ files")
print("write_probdata.py: creating prob_param C++ files")

# read the parameters defined in the parameter files

Expand Down Expand Up @@ -231,11 +230,11 @@ def write_probin(prob_param_files, cxx_prefix):
# we need access to _rt
fout.write(" using namespace amrex;\n")

fout.write(f" amrex::ParmParse pp(\"problem\");\n\n")
fout.write(" amrex::ParmParse pp(\"problem\");\n\n")
for p in params:
if p.is_array():
size = p.size
if (size == "nspec"):
if size == "nspec":
size = "NumSpec"
fout.write(f" for (auto & e : problem::{p.name}) {{\n")
fout.write(f" e = {p.default_format(lang='C++')};\n")
Expand Down