摘要: import torch.nn as nn import torch.functional as F import torch.optim as optim from collections import OrderedDict class Net4(nn.Module):# 从nn.Module 阅读全文
posted @ 2024-01-03 14:36 wenluderen 阅读(4) 评论(0) 推荐(0) 编辑
摘要: import torch.nn as nn import torch.functional as F import torch.optim as optim from collections import OrderedDict class Net3(nn.Module):# 从nn.Module 阅读全文
posted @ 2024-01-03 14:25 wenluderen 阅读(2) 评论(0) 推荐(0) 编辑
摘要: import torch.nn as nn import torch.functional as F import torch.optim as optim from collections import OrderedDict class Net2(nn.Module):# 从nn.Module 阅读全文
posted @ 2024-01-03 14:13 wenluderen 阅读(5) 评论(0) 推荐(0) 编辑
摘要: 第一种语法: 层层堆叠 import torch.nn as nn import torch.functional as F import torch.optim as optim from collections import OrderedDict class Net1(nn.Module):# 阅读全文
posted @ 2024-01-03 13:41 wenluderen 阅读(4) 评论(0) 推荐(0) 编辑