Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion examples/wave/wave-op-var-velocity.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@ def wave_operator(actx, dcoll, c, w):
obj_array.flat(
-op.weak_local_div(dcoll, dd_quad, c_quad*v_quad),
-op.weak_local_grad(dcoll, dd_quad, c_quad*u_quad)
# pylint: disable=invalid-unary-operand-type
) + op.face_mass(
dcoll,
dd_allfaces_quad,
Expand Down
14 changes: 3 additions & 11 deletions grudge/array_context.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,17 +238,11 @@ def _dag_to_compiled_func(self, dict_of_named_arrays: DictOfNamedArrays,
dict_of_named_arrays)

distributed_partition = pt.find_distributed_partition(
# pylint-ignore-reason:
# '_BasePytatoArrayContext' has no
# 'mpi_communicator' member
# pylint: disable=no-member
self.actx.mpi_communicator, dict_of_named_arrays)

if __debug__:
# pylint-ignore-reason:
# '_BasePytatoArrayContext' has no 'mpi_communicator' member
pt.verify_distributed_partition(
self.actx.mpi_communicator, # pylint: disable=no-member
self.actx.mpi_communicator,
distributed_partition)

self.actx._compile_trace_callback(self.f, "post_find_distributed_partition",
Expand All @@ -262,8 +256,6 @@ def _dag_to_compiled_func(self, dict_of_named_arrays: DictOfNamedArrays,
from pytato import number_distributed_tags
prev_mpi_base_tag = self.actx.mpi_base_tag

# type-ignore-reason: 'PytatoPyOpenCLArrayContext' has no 'mpi_communicator'
# pylint: disable=no-member
distributed_partition, new_mpi_base_tag = number_distributed_tags(
self.actx.mpi_communicator,
distributed_partition,
Expand Down Expand Up @@ -372,8 +364,8 @@ def __call__(self, arg_id_to_arg) -> ArrayContainer:
assert isinstance(self.actx, PytatoPyOpenCLArrayContext | PyOpenCLArrayContext)
out_dict = execute_distributed_partition(
self.distributed_partition, self.part_id_to_prg,
self.actx.queue, self.actx.mpi_communicator, # pylint: disable=no-member
allocator=self.actx.allocator, # pylint: disable=no-member
self.actx.queue, self.actx.mpi_communicator,
allocator=self.actx.allocator,
input_args=input_args_for_prg)

def to_output_template(keys, _):
Expand Down
2 changes: 1 addition & 1 deletion grudge/models/euler.py
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ def interp_to_quad(u):

return op.inverse_mass(
dcoll,
volume_fluxes - op.face_mass(dcoll, df, interface_fluxes) # type: ignore[operator]
volume_fluxes - op.face_mass(dcoll, df, interface_fluxes)
)

# }}}
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ doc = [
"sphinx>=4",
]
test = [
"mypy",
"basedpyright",
"pytest",
"ruff"
]
Expand Down
2 changes: 1 addition & 1 deletion test/mesh_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def get_mesh(self, resolution, mesh_order=None):
if mesh_order is None:
mesh_order = 4
return mgen.make_curve_mesh(
self.curve_fn, # pylint: disable=no-member
self.curve_fn,
np.linspace(0.0, 1.0, resolution + 1),
mesh_order)

Expand Down
4 changes: 2 additions & 2 deletions test/test_grudge.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ def _ellipse_surface_area(radius, aspect_ratio):
# NOTE: hardcoded value so we don't need scipy for the test
ellip_e = 1.2110560275684594
else:
from scipy.special import ellipe # pylint: disable=no-name-in-module
from scipy.special import ellipe

ellip_e = ellipe(eccentricity)

Expand Down Expand Up @@ -1093,7 +1093,7 @@ def test_bessel(actx_factory: ArrayContextFactory):
# FIXME: Bessel functions need to brought out of the symbolic
# layer. Related issue: https://github.com/inducer/grudge/issues/93
def bessel_j(actx, n, r):
from grudge import bind, sym # pylint: disable=no-name-in-module
from grudge import bind, sym
return bind(dcoll, sym.bessel_j(n, sym.var("r")))(actx, r=r)

# https://dlmf.nist.gov/10.6.1
Expand Down