Inconsistency in interface for get_eigenmode_coefficients
and EigenModeSource
constructor affecting adjoint solver
#2755
Labels
get_eigenmode_coefficients
and EigenModeSource
constructor affecting adjoint solver
#2755
There is an inconsistency in the interface for the related functions
get_eigenmode_coefficients
and the constructor for theEigenModeSource
class object involving the argumenteig_vol
.get_eigenmode_coefficients
contains an argumenteig_vol
of typemeep.Volume
:meep/python/simulation.py
Lines 4133 to 4143 in 0dc44da
The constructor for the
EigenModeSource
class object does not have aneig_vol
argument and instead useseig_lattice_size
andeig_lattice_center
:meep/python/source.py
Lines 459 to 475 in 0dc44da
These two arguments are used to create an
eig_vol
object in a separate functionadd_source
:meep/python/source.py
Lines 646 to 651 in 0dc44da
eig_vol
and (eig_lattice_center
,eig_lattice_size
) are doing the same thing. It would be good to remove this inconsistency in the interface which currently prevents usingeig_vol
to define anmeep.adjoint.EigenmodeCoefficient
objective function because it is not possible to create an adjoint source. The problem is that the keyword arguments passed toEigenmodeCoefficient
are passed directly toEigenModeSource
in the functionplace_adjoint_source
:meep/python/adjoint/objective.py
Lines 262 to 272 in 0dc44da
The text was updated successfully, but these errors were encountered: