Fix torch version guard at import (#36907)

fix
This commit is contained in:
Raushan Turganbay 2025-03-24 10:33:33 +01:00 committed by GitHub
parent fe4ca2f4a7
commit 48da44be24
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -585,7 +585,7 @@ def _flatten_dynamic_cache_for_fx(cache, spec):
return torch.utils._pytree.tree_flatten(dictionary)[0]
if is_torch_greater_or_equal("2.2"):
if is_torch_greater_or_equal("2.3"):
torch.utils._pytree.register_pytree_node(
DynamicCache,
_flatten_dynamic_cache,