We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f2f050f commit a66a03dCopy full SHA for a66a03d
onnx_diagnostic/helpers/helper.py
@@ -931,7 +931,10 @@ def flatten_object(x: Any, drop_keys: bool = False) -> Any:
931
return flatten_object(list(x.items()), drop_keys=drop_keys)
932
933
if x.__class__.__name__ in {"DynamicCache", "StaticCache"}:
934
- res = flatten_object(x.key_cache) + flatten_object(x.value_cache)
+ from .cache_helper import CacheKeyValue
935
+
936
+ kc = CacheKeyValue(x)
937
+ res = flatten_object(kc.key_cache) + flatten_object(kc.value_cache)
938
return tuple(res)
939
if x.__class__.__name__ == "EncoderDecoderCache":
940
res = flatten_object(x.self_attention_cache) + flatten_object(x.cross_attention_cache)
0 commit comments