Kernels
residual_rms / torch-ext /torch_binding.cpp
drbh
fix: update source and enable limited build
9c26013
Raw History Blame Contribute Delete
426 Bytes
#include <torch/library.h>
#include "registration.h"
#include "torch_binding.h"
TORCH_LIBRARY_EXPAND(TORCH_EXTENSION_NAME, ops) {
// Compute the residual root mean square.
ops.def("residual_rms(Tensor input, Tensor residual, Tensor weight, Tensor output, float epsilon, float scale, int mode, int num_threads) -> ()");
ops.impl("residual_rms", torch::kCUDA, &residual_rms);
}
REGISTER_EXTENSION(TORCH_EXTENSION_NAME)