Skip to content

Commit

Permalink
Try again
Browse files Browse the repository at this point in the history
  • Loading branch information
EricLBuehler committed Mar 12, 2024
1 parent f0644c1 commit 4460683
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions candle-nn/src/layer_norm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ impl crate::Module for LayerNorm {
#[cfg(feature = "cuda")]
impl crate::Module for LayerNorm {
fn forward(&self, x: &Tensor) -> Result<Tensor> {
/*const K_CUDABLOCK_REDUCE_NUM_THREADS: u32 = 512;
const K_CUDABLOCK_REDUCE_NUM_THREADS: u32 = 512;
let cuda_dev = match x.device() {
Device::Cpu | Device::Metal(_) => return self.forward_slow(x),
Device::Cuda(dev) => dev
Expand Down Expand Up @@ -189,7 +189,7 @@ impl crate::Module for LayerNorm {

let layernorm = cuda_dev.get_or_load_func(&format!("layernorm_{}", x.dtype().as_str()), kernels::LAYERNORM)?;
todo!()
*/
/*
use candle::{CpuStorage, CustomOp1, Layout, Result, Shape, Tensor};
struct InnerLayerNorm {
Expand Down Expand Up @@ -297,7 +297,7 @@ impl crate::Module for LayerNorm {
.expect("Time travel has occurred!")
.as_micros();
println!("{}us", end - start);
res
res*/
}
}

Expand Down

0 comments on commit 4460683

Please sign in to comment.