pytoch 模型初始化
摘要:首先、在pytorch中本身带有参数初始化。使用初始化主要是因为在模型构建中的需求 1.使用apply() from torch import nn def weights_init(mod): """对于卷积层和batchnorm进行初始化""" classname=mod.__class__._
阅读全文
posted @ 2020-12-08 17:30
posted @ 2020-12-08 17:30
posted @ 2020-12-08 17:05