improve type annotations
This commit is contained in:
parent
4afc6cf62e
commit
1987ee473a
5 changed files with 17 additions and 17 deletions
|
|
@ -931,7 +931,7 @@ def inner_product( # TODO documentation
|
|||
prop_phase: float = 0,
|
||||
conj_h: bool = False,
|
||||
trapezoid: bool = False,
|
||||
) -> tuple[vcfdfield_t, vcfdfield_t]:
|
||||
) -> complex:
|
||||
|
||||
shape = [s.size for s in dxes[0]]
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ As the z-dependence is known, all the functions in this file assume a 2D grid
|
|||
"""
|
||||
# TODO update module docs
|
||||
|
||||
from typing import Any
|
||||
from typing import Any, cast
|
||||
from collections.abc import Sequence
|
||||
import logging
|
||||
|
||||
|
|
@ -142,7 +142,7 @@ def solve_modes(
|
|||
|
||||
# Wavenumbers assume the mode is at rmin, which is unlikely
|
||||
# Instead, return the wavenumber in inverse radians
|
||||
angular_wavenumbers = wavenumbers * rmin
|
||||
angular_wavenumbers = wavenumbers * cast(complex, rmin)
|
||||
|
||||
order = angular_wavenumbers.argsort()[::-1]
|
||||
e_xys = e_xys[order]
|
||||
|
|
|
|||
Loading…
Reference in a new issue