Commit d1ac27a
authored
fix(merger): handle non-sharded tensors in FSDP2 checkpoint merging (#155)
Non-sharded buffers (e.g. inv_freq) are stored as plain Tensors rather
than DTensors, causing AttributeError on _local_tensor access. Now
falls back to using the tensor directly, and deduplicates identical
copies across ranks instead of concatenating them.1 parent 8260c77 commit d1ac27a
1 file changed
Lines changed: 9 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
101 | | - | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
102 | 105 | | |
103 | 106 | | |
104 | 107 | | |
105 | 108 | | |
106 | 109 | | |
107 | | - | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
108 | 115 | | |
109 | 116 | | |
110 | 117 | | |
| |||
0 commit comments