You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using Newton's method on a form that involves R spaces, and doing a fieldsplit, a PyOP2 error is thrown.
MWE below:
from firedrake import *
M = UnitSquareMesh(5, 5)
V = FunctionSpace(M, "CG", 1)
R = FunctionSpace(M, "R", 0)
Z = V * R
func = Function(Z)
u, l = split(func)
v, w = TestFunctions(Z)
F = (
(u + u**2 - 8) * v * dx
+ l * w * dx
)
newton_solver_parameters = {"snes_type" : "newtonls",
"snes_monitor" : "",
"snes_converged_reason" : "",
"mat_type" : "nest",
"ksp_type" : "fgmres",
"ksp_monitor" : "",
"pc_type": "fieldsplit",
"pc_fieldsplit_type": "schur",
"pc_fieldsplit_schur_fact_type": "full",
"pc_fieldsplit_0_fields": "0",
"pc_fieldsplit_1_fields" : "1",
"fieldsplit_0_ksp_type" : "preonly",
"fieldsplit_0_pc_type" : "lu",
"fieldsplit_0_pc_factor_mat_solver_type" : "mumps",
"fieldsplit_1_ksp_type" : "gmres",
"fieldsplit_1_max_it" : 1,
"fieldsplit_1_convergence_test" : "skip"
}
solve(F == 0, func, solver_parameters=newton_solver_parameters)
The script successfully does an iteration of Newton's method, but it then throws the error
File "/firedrake/src/PyOP2/pyop2/parloop.py", line 421, in reduction_begin
requests.append(self.comm.Iallreduce(glob._data, glob._buf, op=mpi_op))
AttributeError: 'Mat' object has no attribute '_data'
The text was updated successfully, but these errors were encountered:
When using Newton's method on a form that involves R spaces, and doing a fieldsplit, a PyOP2 error is thrown.
MWE below:
The script successfully does an iteration of Newton's method, but it then throws the error
The text was updated successfully, but these errors were encountered: