mmpretrain
mmpretrain copied to clipboard
在终端输出中没有mode train只会打印mode val, 怎样设置才能打印mode train
举例例子,如下这种mode train 怎样设置终端才打印 {"mode": "train", "epoch": 1, "iter": 100, "lr": 0.01, "memory": 4745, "data_time": 0.42691, "loss": 6.9082, "top-1": 0.15234, "top-5": 0.57031, "time": 0.84829}
Please use English or English & Chinese for issues so that we could have broader discussion.
try to modify your head config, for example resnet50 head
head=dict(
type='LinearClsHead',
num_classes=1000,
in_channels=2048,
loss=dict(
type='LabelSmoothLoss',
label_smooth_val=0.1,
num_classes=1000,
reduction='mean',
loss_weight=1.0),
topk=(1, 5),
cal_acc=True))
数据集很小batchsize很大就不打印,可以在default_runtime.py里设置interval小一些 log_config = dict( interval=100, hooks=[ dict(type='TextLoggerHook'), # dict(type='TensorboardLoggerHook') ])