First time here? Checkout the FAQ!
x
+2 votes
by (180 points)

Hi all, 

I have been trying to use openCarp's docker on Windows to do a Laplace Solve. I get the following error: 

Error: L5 : elliptic PDE (PETSc) solver diverged. Reason: -3

The same command seems to work on macOS and linux. Specifically, the command I'm running is as follows: 

docker run --rm --volume=D:/PATH/TO/FILES:/shared:z --workdir=/shared docker.opencarp.org/opencarp/opencarp:latest openCARP +F parameterFile.par -simID outputDirecrotyName 

I'd appreciate the help. In here, -3 seems to refer to running out of iterations before converging, but why then would it work on the other operating systems? Especially if I'm running openCarp through Docker! I'm happy to share the output I'm getting and any more information you might need. 

Many thanks, 

Jose

2 Answers

0 votes
by (4.3k points)
Hi Jose,

This behavior is unexpected indeed.

Please share a minimal example to reproduce this issue (.par file and if required mesh)
0 votes
by (180 points)
edited by

Hi again, thank you for your response. 

Apologies I haven't checked back, but I wanted to be sure of the problem. I ran it again on three systems: ubuntu 16.04, macOS and windows10. To my surprise, only the macOS converged with the same files. 

To look more closely at the outputs, I ran the openCARP docker container with the -ti option in both windows and macOS, adding the folder with my data as in per the following command: 

docker run --rm --volume=/path/to/data:/shared:z --workdir=/shared -ti docker.opencarp.org/opencarp/opencarp:latest

Then on both I ran the same command: 

openCARP +F parameter_file.par -simID in_docker_OUTPUT 

The outputs differ in some obvious places (like the "done in XX.YY seconds" messages) and in some not so obvious places! Only in macOS, I get a message:
 

elliptic PDE (PETSc) solver: switching to default settings "-ksp_type cg -pc_type hypre -pc_hypre_type boomeramg -pc_hypre_boomeramg_max_iter 1 -pc_hypre_boomeramg_strong_threshold 0.0 -options_left"

You can see in the link below a screenshot of a diff I did of both outputs. It seems this might be the problem, do you know a way I could set the solver to default settings? Is this available as options when calling the openCARP command or parameter_file?  

Link to diff screenshot

Update: Workaround 

Given the previous information, I thought of trying a workaround that meant setting specifically the solver's parameters, this is setting a few other parameters, it looks long, but it's really simple. The command changes to: 
docker run --rm --volume=/path/to/files:/shared:z --workdir=/shared docker.opencarp.org/opencarp/opencarp:latest openCARP -ellip_use_pt 0 -parab_use_pt 0 -parab_options_file /usr/local/lib/python3.6/dist-packages/carputils-0.0.0-py3.6-linux-x86_64.egg/carputils/resources/petsc_options/ilu_cg_opts -ellip_options_file /usr/local/lib/python3.6/dist-packages/carputils-0.0.0-py3.6-linux-x86_64.egg/carputils/resources/petsc_options/amg_cg_opts +F carpf_laplace_PA.par -simID output_directory
I'll carry on running tests and come back to this thread if necessary. I still do not understand why would the docker container decide to run different on those systems! But anyway, hope this helps someone. 
Welcome to openCARP Q&A. Ask questions and receive answers from other members of the community. For best support, please use appropriate TAGS!
architecture, carputils, documentation, experiments, installation-containers-packages, limpet, slimfem, website, governance
...