FFC compiler error with latest fenics from conda-forge

Fenics version fenics=2019.1.0=py38h578d9bd_19 from conda-forge gives the following error during FFC JIT compilation

UMFPACK V5.7.8 (Nov 9, 2018): ERROR: out of memory

However fenics=2019.1.0=py38.8 succesfully compiles and runs the same problem.

It’s bizarre that this error appears during JIT compilation. It’s a pretty standard UMFPACK error where you’ve hit the (very low) default memory limit. Try changing your solver to mumps, or running in parallel, and see if you hit the same issue.

A question about running in parallel.

For now I just do python script.py and it appears to use all the cores I have, so I think it does run in parallel (also same script runs faster on larger number of cores). Is there anything extra I should do to run in parallel?

Also the problem is nonlinear, will adding the follwing actually help?

solver_parameters={"newton_solver": {"linear_solver": "mumps"}}

If all your cores are being dominated (where number of cores is > 1) by a serial run of a python script, something is horribly wrong with your system.

To run in parallel on two processes, for example, you simply invoke mpirun -np 2 python3 script.py

I don’t follow this. You mean something is wrong with the variational problem I have setup or with my fenics installation?

maybe you’re running an antiquated version of FEniCS which has crude support for concurrency. Try setting the environment variable export OMP_NUM_THREADS=1 and then rerunning in serial to make sure you’re not using more than one process.

FEniCS versions 2018 and beyond should not have this problem.

export OMP_NUM_THREADS=1 does limits to just a single process running on 1 core.

I installed fenics from conda-forge using

conda create -n fenicsproject -c conda-forge fenics=2019.1.0=py38_8

The latest version of fenics on conda-forge is fenics=2019.1.0=py39hf3d152e_19 which
gives the original UMFPACK error. Which version of fenics should I use?

You should use whichever version suits your needs. Have you tried the mumps solver? UMFPACK is just the default for serial computations.

Yes I tried mumps, but it ends up with a runtime error after solving the system for some number of iterations.

Newton solver did not converge because maximum number of iterations reached.

I am getting slightly confused now, I will create a MWE and get back. Can you please give me some references on solving nonlinear problems?