Skip to content

Commit

Permalink
auto format by CI
Browse files Browse the repository at this point in the history
  • Loading branch information
oneflow-ci-bot committed Jan 8, 2025
1 parent 8558e58 commit ce66dff
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion oneflow/core/autograd/gradient_funcs/layer_norm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ Maybe<void> LayerNorm::Apply(const LayerNormCaptureState* ctx, const TensorTuple
*in_grads = *JUST(functional::FuseLayerNormGrad(
dy, x, mean, inv_variance, gamma, begin_norm_axis, begin_params_axis, ctx->epsilon));
} else {
UNIMPLEMENTED();
UNIMPLEMENTED();
}
}
} else {
Expand Down
4 changes: 2 additions & 2 deletions oneflow/user/kernels/layer_norm_cpu_kernel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ class FuseLayerNormGradCpuKernel final : public user_op::OpKernel {
void Compute(user_op::KernelComputeContext* ctx) const override { TODO(); };
};

#define REGISTER_FUSE_LAYER_NORM_GRAD_CPU_KERNEL(dtype) \
REGISTER_USER_KERNEL("fuse_layer_norm_grad") \
#define REGISTER_FUSE_LAYER_NORM_GRAD_CPU_KERNEL(dtype) \
REGISTER_USER_KERNEL("fuse_layer_norm_grad") \
.SetCreateFn<LayerNormGradCpuKernel<dtype>>() \
.SetIsMatchedHob((user_op::HobDeviceType() == DeviceType::kCPU) \
&& (user_op::HobDataType("dy", 0) == GetDataType<dtype>::value));
Expand Down

0 comments on commit ce66dff

Please sign in to comment.