File tree Expand file tree Collapse file tree 3 files changed +22
-5
lines changed
Expand file tree Collapse file tree 3 files changed +22
-5
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,9 @@ get the latest kernel build from the `v1` branch.
2828Kernels within a version branch must never break the API or remove builds
2929for older PyTorch versions. This ensures that your code will continue to work.
3030
31+ Some kernels have not yet been updated to use versioning yet. In these cases,
32+ you can use ` get_kernel ` without the ` version ` argument.
33+
3134## Checking Kernel Availability
3235
3336You can check if a particular version of a kernel supports the environment
Original file line number Diff line number Diff line change @@ -170,7 +170,18 @@ kernel_layer_mapping = {
170170}
171171```
172172
173- You can register such a mapping using ` register_kernel_mapping ` :
173+ This uses version ` 1 ` of the ` SiluAndMul ` kernel layer from
174+ ` kernels-community/activation ` for the ` cuda ` and ` rocm ` backends. Kernel
175+ layers are versioned using a major version number. Using ` version=1 `
176+ will get the latest kernel build from the ` v1 ` branch. Kernel layers
177+ within a version branch must never break the API or remove builds for
178+ older PyTorch versions. This ensures that your code will continue to
179+ work.
180+
181+ Some kernels have not yet been updated to use versioning yet. In these cases,
182+ you can use ` LayerRepository ` without the ` version ` argument.
183+
184+ You can register a mapping, like the one above, using ` register_kernel_mapping ` :
174185
175186``` python
176187register_kernel_mapping(kernel_layer_mapping)
Original file line number Diff line number Diff line change @@ -84,9 +84,12 @@ def select_revision_or_version(
8484 elif version is not None :
8585 return resolve_version_spec_as_ref (repo_id , version ).target_commit
8686
87- warnings .warn (
88- "Future versions of `kernels` (>=0.14) will require specifying a kernel version or revision."
89- "See: https://huggingface.co/docs/kernels/migration"
90- )
87+ # Re-enable once we have proper UX on the hub for showing the
88+ # kernel versions.
89+ #
90+ # warnings.warn(
91+ # "Future versions of `kernels` (>=0.14) will require specifying a kernel version or revision."
92+ # "See: https://huggingface.co/docs/kernels/migration"
93+ # )
9194
9295 return "main"
You can’t perform that action at this time.
0 commit comments