[RL] Skip rotary cache tensors in weight checker (#27692)

This commit is contained in:
Zilin Zhu
2026-08-05 18:22:12 -07:00
committed by GitHub
parent ceaeca0b9e
commit f01f706960
@@ -194,6 +194,9 @@ def _check_tensors(
actual_should_compare,
actual_comparable,
) in zip(expect_tensors, actual_tensors, strict=True):
if ".cos_sin_cache" in expect_name:
# skip cos/sin cache which is deterministic from shape and dtype and may have different shapes due to different implementations.
continue
assert expect_name == actual_name, f"{expect_name=} {actual_name=}"
assert (
should_compare == actual_should_compare