摘要:
model.eval()和torch.no_grad()的区别 https://blog.csdn.net/qq_41813454/article/details/135129279 import torch import torch.nn as nn import torch.nn.functio 阅读全文
摘要:
1、nn.Parameter函数 2、torch.mm 和torch.matmul区别 都是 PyTorch 中用于矩阵乘法的函数,但它们在使用上有细微的差别 import torch import torch.nn as nn import torch.nn.functional as F cla 阅读全文
摘要:
使用torch.nn.LazyLinear(output)实现延迟初始化 import torch import torch.nn as nn class MyModel(nn.Module): def __init__(self): super(MyModel, self).__init__() 阅读全文
摘要:
![](https://img2024.cnblogs.com/blog/2506674/202408/2506674-20240825110451280-1080924502.png) 阅读全文
摘要:
![](https://img2024.cnblogs.com/blog/2506674/202408/2506674-20240825110338159-1534763745.png) ![](https://img2024.cnblogs.com/blog/2506674/202408/2506674-20240825110353076-1835101190.png) ![](https:// 阅读全文
摘要:
torch.rand和torch.randn的区别: 阅读全文