摘要:
当我们的模型训练好之后,需要将其参数(或整个模型)保存起来以便日后直接使用。pytorch提供了两种方法帮助我们快速、方便地保存训练好的模型 步骤 训练模型 保存模型 加载模型 训练模型 我们以二分类问题为例,训练一个神经网络,代码如下: import torch import torch.nn.f 阅读全文
posted @ 2021-09-13 21:43 foghorn 阅读(351) 评论(0) 推荐(0)
posted @ 2021-09-13 21:43 foghorn 阅读(351) 评论(0) 推荐(0)
posted @ 2021-09-13 20:58 foghorn 阅读(543) 评论(0) 推荐(0)
posted @ 2021-09-13 16:03 foghorn 阅读(186) 评论(0) 推荐(0)