detect duplicates in threads#1342
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1342 +/- ##
==========================================
+ Coverage 78.43% 78.49% +0.06%
==========================================
Files 50 50
Lines 3593 3608 +15
==========================================
+ Hits 2818 2832 +14
- Misses 775 776 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
penelopeysm
left a comment
There was a problem hiding this comment.
Thanks for taking this on @hardik-xi11! I like it, just one minor comment. As usual, can you bump the patch and add a changelog too please.
| skel = DynamicPPL.VarNamedTuples.skeleton(acc2.values) | ||
| new_values = acc1.values | ||
| for (vn, val) in pairs(acc2.values) | ||
| top_sym = DynamicPPL.AbstractPPL.getsym(vn) | ||
| template_from_acc2_values = get( | ||
| skel.data, top_sym, DynamicPPL.VarNamedTuples.NoTemplate() | ||
| ) |
There was a problem hiding this comment.
I don't think you need to make the skeleton here; you can just write template_from_acc2_vales = get(acc2.values.data, top_sym, NoTemplate()) since the actual value in the VNT doesn't matter, only the structure.
There was a problem hiding this comment.
There's an interesting edge case here which is what should the template be if acc2 and acc1 have different templates, in other words, what happens if acc1 and acc2 both already contain x[1]. I think currently DynamicPPL will ignore the template and it will just use the structure inside acc1. That's not a problem in and of itself, but it might be worth a comment somewhere.
9d27e00 to
efd0c04
Compare
|
everything should be good now |
final changes to close #1157