Skip to content
Snippets Groups Projects
Commit 3269b822 authored by Timo Koch's avatar Timo Koch
Browse files

[python] Simplify parameter construction

parent 2d8fbef1
No related branches found
No related tags found
1 merge request!2681Feature/python main file
...@@ -55,7 +55,7 @@ def BoundaryTypes(numEq=1): ...@@ -55,7 +55,7 @@ def BoundaryTypes(numEq=1):
return globals()[cacheKey]() return globals()[cacheKey]()
def Parameters(*, file=None, dict={}): def Parameters(dict={}, file=None):
parametersType = "Dumux::Parameters" parametersType = "Dumux::Parameters"
includes = ["dumux/common/parameters.hh", "dumux/python/common/parameters.hh"] includes = ["dumux/common/parameters.hh", "dumux/python/common/parameters.hh"]
moduleName = "parameters_" + hashIt(parametersType) moduleName = "parameters_" + hashIt(parametersType)
......
...@@ -27,7 +27,7 @@ if diffMethod not in ["analytic", "numeric"]: ...@@ -27,7 +27,7 @@ if diffMethod not in ["analytic", "numeric"]:
raise NotImplementedError(diffMethod + " must be analytic or numeric") raise NotImplementedError(diffMethod + " must be analytic or numeric")
# Initialize the paramaters # Initialize the paramaters
parameters = Parameters(dict={ parameters = Parameters({
"Problem.EnableGravity": True, "Problem.EnableGravity": True,
"SpatialParams.Porosity": 0.3, "SpatialParams.Porosity": 0.3,
"SpatialParams.Permeability": 1e-8, "SpatialParams.Permeability": 1e-8,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment