tidy3d.plugins.autograd.invdes.make_filter#
- class make_filter[source]#
Bases:
Create a filter function based on the specified kernel type and size.
- Parameters:
radius (Union[float, Tuple[float, ...]] = None) β The radius of the kernel. Can be a scalar or a tuple.
dl (Union[float, Tuple[float, ...]] = None) β The grid spacing. Can be a scalar or a tuple.
size_px (Union[int, Tuple[int, ...]] = None) β The size of the kernel in pixels for each dimension. Can be a scalar or a tuple.
normalize (bool = True) β Whether to normalize the kernel so that it sums to 1.
padding (PaddingType = "reflect") β The padding mode to use.
filter_type (KernelType) β The type of kernel to create (
circular
orconic
).
- Returns:
A function that applies the created filter to an input array.
- Return type:
Callable[[np.ndarray], np.ndarray]
Inherited Common Usage