You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+10-3Lines changed: 10 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -108,6 +108,7 @@ Migration guide:
108
108
This function is deprecated. Use the `torch.nn.attention.sdpa_kernel` context manager instead.
109
109
110
110
Migration guide:
111
+
111
112
Each boolean input parameter (defaulting to true unless specified) of `sdp_kernel` corresponds to a `SDPBackened`. If the input parameter is true, the corresponding backend should be added to the input list of `sdpa_kernel`.
112
113
113
114
### TOR102 Unsafe use of function
@@ -117,6 +118,7 @@ Each boolean input parameter (defaulting to true unless specified) of `sdp_kerne
117
118
The use of `torch.load` without the `weights_only` parameter is unsafe. Loading an untrusted pickle file may lead to the execution of arbitrary malicious code and potential security issues.
118
119
119
120
Migration Guide:
121
+
120
122
Explicitly set `weights_only=False` only if you trust the data you load and full pickle functionality is needed,
121
123
122
124
```
@@ -126,31 +128,36 @@ otherwise set `weights_only=True`.
Public functions are well-documented and supported by the library maintainers and the use of the non-public function `torch.utils.data._utils.collate.default_collate` is discouraged as it can can change without notice in future versions, leading to potential breakage in your code.
134
137
135
138
Migration Guide:
139
+
136
140
For better maintainability and compatibility, please use the public function `torch.utils.data.dataloader.default_collate` instead.
137
141
138
142
### TOR201 Use of deprecated parameter
139
143
140
144
#### Model(pretrained=True)
141
145
142
-
The parameter `pretrained` has been deprecated in TorchVision models since PyTorch version 1.12.0. The `weights` parameter should be used instead
146
+
The parameter `pretrained` has been deprecated in TorchVision models since PyTorch version 1.12.0. The `weights` parameter should be used instead.
147
+
143
148
```
144
149
model = SomeModel(weights='<path_or_identifier_to_weights>')
145
150
```
151
+
146
152
### TOR202 Use of deprecated function
147
153
148
154
#### transform v2.ToTensor()
149
155
150
-
The `transform v2.ToTensor()` is deprecated and will be removed in a future release.
151
-
Instead, please use `v2.Compose([v2.ToImage(), v2.ToDtype(torch.float32, scale=True)])`.
156
+
The `transform v2.ToTensor()` is deprecated and will be removed in a future release. Instead, please use `v2.Compose([v2.ToImage(), v2.ToDtype(torch.float32, scale=True)])`.
0 commit comments