Build uploaded using `kernels`.
Browse filesFiles changed (19)
- .gitattributes+2
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__init__.py+3-3
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/__init__.cpython-313.pyc
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/_ops.cpython-313.pyc
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/functions.cpython-313.pycAdded
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/layers.cpython-313.pyc
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so → build/torch28-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_06e17fa.abi3.soRenamed+1-1
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/_ops.py+3-3
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/functions.pyAdded+23
- build/torch28-metal-aarch64-darwin/mlx_rmsnorm/layers.py+1-22
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__init__.py+3-3
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/__init__.cpython-313.pyc
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/_ops.cpython-313.pyc
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/functions.cpython-313.pycAdded
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/layers.cpython-313.pyc
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so → build/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_06e17fa.abi3.soRenamed+1-1
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/_ops.py+3-3
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/functions.pyAdded+23
- build/torch29-metal-aarch64-darwin/mlx_rmsnorm/layers.py+1-22
36 unmodified lines37383936 unmodified linesbuild/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_97571a8_dirty.abi3.so filter=lfs diff=lfs merge=lfs -textbuild/torch28-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so filter=lfs diff=lfs merge=lfs -textbuild/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so filter=lfs diff=lfs merge=lfs -text36 unmodified lines373839404136 unmodified linesbuild/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_97571a8_dirty.abi3.so filter=lfs diff=lfs merge=lfs -textbuild/torch28-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so filter=lfs diff=lfs merge=lfs -textbuild/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so filter=lfs diff=lfs merge=lfs -textbuild/torch28-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_06e17fa.abi3.so filter=lfs diff=lfs merge=lfs -textbuild/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_06e17fa.abi3.so filter=lfs diff=lfs merge=lfs -text
123from .layers import RMSNorm, rmsnorm_forward, rmsnorm_backward__all__ = ["RMSNorm", "rmsnorm_forward", "rmsnorm_backward"]123from .functions import rmsnorm_forward, rmsnorm_backwardfrom . import layers__all__ = ["layers", "rmsnorm_forward", "rmsnorm_backward"]
123version https://git-lfs.github.com/spec/v1oid sha256:22dcc9b26a28ff2c1cc34697bd25bf55eeb9cd9d4f1eb32a352ed2343fecbe6dsize 219168123version https://git-lfs.github.com/spec/v1oid sha256:6064021fd19860d705283dfb31cd15e6e4e1776dc4c1af0e29c8ee421deafa64size 219168
123456789import torchfrom . import _mlx_rmsnorm_57d865fops = torch.ops._mlx_rmsnorm_57d865fdef add_op_namespace_prefix(op_name: str):"""Prefix op by namespace."""return f"_mlx_rmsnorm_57d865f::{op_name}"123456789import torchfrom . import _mlx_rmsnorm_06e17faops = torch.ops._mlx_rmsnorm_06e17fadef add_op_namespace_prefix(op_name: str):"""Prefix op by namespace."""return f"_mlx_rmsnorm_06e17fa::{op_name}"
1234567891011121314151617181920212223import torchfrom ._ops import ops
def rmsnorm_forward(x: torch.Tensor, weight: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor: original_shape = x.shape x = x.view(-1, x.shape[-1]) weight = weight.view(-1) output = torch.zeros_like(x) ops.launch_forward_kernel(x, weight, output, epsilon) output = output.view(original_shape) return output
def rmsnorm_backward(x: torch.Tensor, weight: torch.Tensor, grad_output: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor: original_shape = x.shape x = x.view(-1, x.shape[-1]) weight = weight.view(-1) grad_output = grad_output.view(-1) grad_input = torch.zeros_like(x) grad_weight = torch.zeros_like(weight) ops.launch_backward_kernel(x, weight, grad_output, grad_input, grad_weight, epsilon) grad_input = grad_input.view(original_shape) grad_weight = grad_weight.view(original_shape) return grad_input, grad_weight123454 unmodified lines1011121314151617181920212223242526272829303132from ._ops import opsimport torchclass RMSNorm(torch.nn.Module):4 unmodified linesreturn rmsnorm_forward(x, self.weight, self.eps)def rmsnorm_forward(x: torch.Tensor, weight: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor:original_shape = x.shapex = x.view(-1, x.shape[-1])weight = weight.view(-1)output = torch.zeros_like(x)ops.launch_forward_kernel(x, weight, output, epsilon)output = output.view(original_shape)return outputdef rmsnorm_backward(x: torch.Tensor, weight: torch.Tensor, grad_output: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor:original_shape = x.shapex = x.view(-1, x.shape[-1])weight = weight.view(-1)grad_output = grad_output.view(-1)grad_input = torch.zeros_like(x)grad_weight = torch.zeros_like(weight)ops.launch_backward_kernel(x, weight, grad_output, grad_input, grad_weight, epsilon)grad_input = grad_input.view(original_shape)grad_weight = grad_weight.view(original_shape)return grad_input, grad_weight12344 unmodified lines91011from .functions import rmsnorm_forwardimport torchclass RMSNorm(torch.nn.Module):4 unmodified linesreturn rmsnorm_forward(x, self.weight, self.eps)
123from .layers import RMSNorm, rmsnorm_forward, rmsnorm_backward__all__ = ["RMSNorm", "rmsnorm_forward", "rmsnorm_backward"]123from .functions import rmsnorm_forward, rmsnorm_backwardfrom . import layers__all__ = ["layers", "rmsnorm_forward", "rmsnorm_backward"]
123version https://git-lfs.github.com/spec/v1oid sha256:a507684a2ed7b127800e22962811212ac657ac126665f645e4a4bfe78e4bb3d8size 220128123version https://git-lfs.github.com/spec/v1oid sha256:3eb0d24dc5c019fa77403103e936cff377e6003f2537fdfd0892f0a0f73ae922size 220128
123456789import torchfrom . import _mlx_rmsnorm_57d865fops = torch.ops._mlx_rmsnorm_57d865fdef add_op_namespace_prefix(op_name: str):"""Prefix op by namespace."""return f"_mlx_rmsnorm_57d865f::{op_name}"123456789import torchfrom . import _mlx_rmsnorm_06e17faops = torch.ops._mlx_rmsnorm_06e17fadef add_op_namespace_prefix(op_name: str):"""Prefix op by namespace."""return f"_mlx_rmsnorm_06e17fa::{op_name}"
1234567891011121314151617181920212223import torchfrom ._ops import ops
def rmsnorm_forward(x: torch.Tensor, weight: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor: original_shape = x.shape x = x.view(-1, x.shape[-1]) weight = weight.view(-1) output = torch.zeros_like(x) ops.launch_forward_kernel(x, weight, output, epsilon) output = output.view(original_shape) return output
def rmsnorm_backward(x: torch.Tensor, weight: torch.Tensor, grad_output: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor: original_shape = x.shape x = x.view(-1, x.shape[-1]) weight = weight.view(-1) grad_output = grad_output.view(-1) grad_input = torch.zeros_like(x) grad_weight = torch.zeros_like(weight) ops.launch_backward_kernel(x, weight, grad_output, grad_input, grad_weight, epsilon) grad_input = grad_input.view(original_shape) grad_weight = grad_weight.view(original_shape) return grad_input, grad_weight123454 unmodified lines1011121314151617181920212223242526272829303132from ._ops import opsimport torchclass RMSNorm(torch.nn.Module):4 unmodified linesreturn rmsnorm_forward(x, self.weight, self.eps)def rmsnorm_forward(x: torch.Tensor, weight: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor:original_shape = x.shapex = x.view(-1, x.shape[-1])weight = weight.view(-1)output = torch.zeros_like(x)ops.launch_forward_kernel(x, weight, output, epsilon)output = output.view(original_shape)return outputdef rmsnorm_backward(x: torch.Tensor, weight: torch.Tensor, grad_output: torch.Tensor, epsilon: float = 1e-5) -> torch.Tensor:original_shape = x.shapex = x.view(-1, x.shape[-1])weight = weight.view(-1)grad_output = grad_output.view(-1)grad_input = torch.zeros_like(x)grad_weight = torch.zeros_like(weight)ops.launch_backward_kernel(x, weight, grad_output, grad_input, grad_weight, epsilon)grad_input = grad_input.view(original_shape)grad_weight = grad_weight.view(original_shape)return grad_input, grad_weight12344 unmodified lines91011from .functions import rmsnorm_forwardimport torchclass RMSNorm(torch.nn.Module):4 unmodified linesreturn rmsnorm_forward(x, self.weight, self.eps)
.gitattributes+2
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__init__.py+3-3
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/__init__.cpython-313.pyc
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/_ops.cpython-313.pyc
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/functions.cpython-313.pycAdded
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/layers.cpython-313.pyc
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so → build/torch28-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_06e17fa.abi3.soRenamed+1-1
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/_ops.py+3-3
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/functions.pyAdded+23
build/torch28-metal-aarch64-darwin/mlx_rmsnorm/layers.py+1-22
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__init__.py+3-3
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/__init__.cpython-313.pyc
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/_ops.cpython-313.pyc
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/functions.cpython-313.pycAdded
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/__pycache__/layers.cpython-313.pyc
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_57d865f.abi3.so → build/torch29-metal-aarch64-darwin/mlx_rmsnorm/_mlx_rmsnorm_06e17fa.abi3.soRenamed+1-1
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/_ops.py+3-3
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/functions.pyAdded+23
build/torch29-metal-aarch64-darwin/mlx_rmsnorm/layers.py+1-22