提交 8db51c70 authored 作者: Glenn Jocher's avatar Glenn Jocher

tb_writer bug fix

上级 4052603e
...@@ -195,8 +195,9 @@ def train(hyp): ...@@ -195,8 +195,9 @@ def train(hyp):
c = torch.tensor(labels[:, 0]) # classes c = torch.tensor(labels[:, 0]) # classes
# cf = torch.bincount(c.long(), minlength=nc) + 1. # cf = torch.bincount(c.long(), minlength=nc) + 1.
# model._initialize_biases(cf.to(device)) # model._initialize_biases(cf.to(device))
plot_labels(labels) if tb_writer:
tb_writer.add_histogram('classes', c, 0) plot_labels(labels)
tb_writer.add_histogram('classes', c, 0)
# Check anchors # Check anchors
check_anchors(dataset, model=model, thr=hyp['anchor_t'], imgsz=imgsz) check_anchors(dataset, model=model, thr=hyp['anchor_t'], imgsz=imgsz)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论