CLRNet icon indicating copy to clipboard operation
CLRNet copied to clipboard

The size of the weights I trained myself is different from the official one.

Open CrazyMustard-404 opened this issue 2 years ago • 1 comments

Hello author, thank you for your outstanding contribution.

When I trained the Tusimple dataset using "python configs/clrnet/clr_resnet18_tusimple.py --gpus 0", the weight size of the 10th epoch I obtained was 104.6MB, which is different from the official size of 47.3M.

However, the weights I trained can achieve correct inference in detect.py. Due to this 104.6MB weight, I cannot smoothly convert it to ONNX.

CrazyMustard-404 avatar May 18 '23 07:05 CrazyMustard-404

Because it saves states of the net, optimizer, scheduler and recorder simultaneously: https://github.com/Turoad/CLRNet/blob/7269e9d1c1c650343b6c7febb8e764be538b1aed/clrnet/utils/net_utils.py#L8-L20 To make your model size consistent with the one provided in the https://github.com/Turoad/CLRNet/releases, simply modify code above to only save the state of the net.

liyufan avatar Sep 25 '23 09:09 liyufan