Skip to content

Commit 1c256b5

Browse files
luyao-cvBobholamovic
authored andcommitted
fix ppdet/utils/states (PaddlePaddle#8421)
* fix a code * fix the tensor to float
1 parent 47d7ee5 commit 1c256b5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ppdet/utils/stats.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ def update(self, stats):
7474
for k in stats.keys()
7575
}
7676
for k, v in self.meters.items():
77-
v.update(stats[k].numpy())
77+
v.update(float(stats[k]))
7878

7979
def get(self, extras=None):
8080
stats = collections.OrderedDict()

0 commit comments

Comments
 (0)