What if loss suddenly changes to zero in Pytorch?
This article will explain in detail what to do when loss suddenly changes to zero in Pytorch. The editor thinks it is very practical, so I share it with you as a reference. I hope you can get something after reading this article.
Problem / / loss suddenly becomes 0python train.py-b=8INFO: Using device cpuINFO: Network: 1 input channels 7 output channels (classes) Bilinear upscalingINFO: Creating dataset with 868 examplesINFO: Starting training: Epochs: 5 Batch size: 8 Learning rate: 0.001 Training size: 782Validation size: 86 Checkpoints: True Device: cpu Images scaling: 1 Epoch 1amp 5: 10% | █▏ | 80 Universe 782 [01:33]