Skip to content

Commit f3d0f8e

Browse files
Gregory Robertsyaugenst-flex
authored andcommitted
fix(adjoint): only trigger symmetric adjoint simulation warning when grouping by more than 1 port
1 parent b13c9de commit f3d0f8e

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1313
### Fixed
1414
- Fixed missing amplitude factor and handling of negative normal direction case when making adjoint sources from `DiffractionMonitor`.
1515
- Improved the robustness of batch jobs. The batch state, including all `task_ids`, is now saved to `batch.hdf5` immediately after upload. This fixes an issue where an interrupted batch (e.g., due to a kernel crash or network loss) would be unrecoverable.
16+
- Fixed warning for running symmetric adjoint simulations by port to not trigger when there is a single port.
1617

1718
## [2.9.0] - 2025-08-04
1819

tidy3d/components/data/sim_data.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1192,7 +1192,7 @@ def _process_adjoint_sources(self, adj_srcs: list[SourceType]) -> list[AdjointSo
11921192
# warn if the forward simulation had symmetry and we are grouping by port, which
11931193
# which means the individual adjoint simulations may not respect the original symmetry
11941194
#
1195-
if np.any(np.abs(self.simulation.symmetry) > 0):
1195+
if np.any(np.abs(self.simulation.symmetry) > 0) and (num_ports > 1):
11961196
log.warning(
11971197
"The adjoint simulations for this problem are being broken into "
11981198
"multiple simulations that may not individually respect the symmetry of the "

0 commit comments

Comments
 (0)