diff --git a/docs/meshtags.py b/docs/meshtags.py index 8f3e2f0..caea72b 100644 --- a/docs/meshtags.py +++ b/docs/meshtags.py @@ -75,7 +75,7 @@ def verify_meshtags(filename: Path): np.testing.assert_allclose( entity_midpoints[i][global_pos], midpoint, - err_msg=f"{prefix}: Midpoint ({i , global_pos}) do not match", + err_msg=f"{prefix}: Midpoint ({i, global_pos}) do not match", ) print(f"{prefix} Matching of all entities of dimension {i} successful") diff --git a/docs/original_checkpoint.py b/docs/original_checkpoint.py index 0f25e78..b0a80b7 100644 --- a/docs/original_checkpoint.py +++ b/docs/original_checkpoint.py @@ -36,7 +36,7 @@ def create_xdmf_mesh(filename: Path): with dolfinx.io.XDMFFile(MPI.COMM_WORLD, filename.with_suffix(".xdmf"), "w") as xdmf: xdmf.write_mesh(mesh) xdmf.write_meshtags(facet_tag, mesh.geometry) - print(f"{mesh.comm.rank+1}/{mesh.comm.size} Mesh written to {filename.with_suffix('.xdmf')}") + print(f"{mesh.comm.rank + 1}/{mesh.comm.size} Mesh written to {filename.with_suffix('.xdmf')}") mesh_file = Path("MyMesh.xdmf") @@ -79,7 +79,7 @@ def write_function( name="Output", ) print( - f"{mesh.comm.rank+1}/{mesh.comm.size} Function written to ", + f"{mesh.comm.rank + 1}/{mesh.comm.size} Function written to ", f"{function_filename.with_suffix('.bp')}", ) diff --git a/docs/time_dependent_mesh.py b/docs/time_dependent_mesh.py index 21d149d..7625f65 100644 --- a/docs/time_dependent_mesh.py +++ b/docs/time_dependent_mesh.py @@ -29,7 +29,7 @@ def compute_volume(mesh, time_stamp): vol_local = dolfinx.fem.assemble_scalar(vol_form) vol_glob = mesh.comm.allreduce(vol_local, op=MPI.SUM) if mesh.comm.rank == 0: - print(f"{mesh.comm.rank+1}/{mesh.comm.size} Time: {time_stamp} Mesh Volume: {vol_glob}") + print(f"{mesh.comm.rank + 1}/{mesh.comm.size} Time: {time_stamp} Mesh Volume: {vol_glob}") def write_meshes(filename: Path): diff --git a/tests/create_legacy_checkpoint.py b/tests/create_legacy_checkpoint.py index 07a8fb7..04006a1 100644 --- a/tests/create_legacy_checkpoint.py +++ b/tests/create_legacy_checkpoint.py @@ -21,9 +21,9 @@ import adios4dolfinx a4d_version = version("adios4dolfinx") -assert ( - a4d_version < "0.7.2" -), f"Creating a legacy checkpoint requires adios4dolfinx < 0.7.2, you have {a4d_version}." +assert a4d_version < "0.7.2", ( + f"Creating a legacy checkpoint requires adios4dolfinx < 0.7.2, you have {a4d_version}." +) def f(x):