Skip to content

Commit

Permalink
internal
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 674890668
  • Loading branch information
yifenglou authored and langfun authors committed Sep 15, 2024
1 parent e626b0c commit e097dd5
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions langfun/core/eval/matching.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,9 @@ def save(
# Save matches.
pg.save(
[
pg.Dict(input=input, output=output)
pg.symbolic.deref(
pg.Dict(input=input, output=output), recursive=True
)
for input, output, _ in self.matches
],
os.path.join(self.dir, Matching.MATCHES_JSON),
Expand All @@ -190,7 +192,9 @@ def save(
[
# We force the output to be dict as its type may be defined
# within functors which could be deserialized.
pg.Dict(input=input, output=output)
pg.symbolic.deref(
pg.Dict(input=input, output=output), recursive=True
)
for input, output, _ in self.mismatches
],
os.path.join(self.dir, Matching.MISMATCHES_JSON),
Expand Down

0 comments on commit e097dd5

Please sign in to comment.