We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 93bdbc6 commit d94ff95Copy full SHA for d94ff95
ggml/src/ggml-vulkan/vulkan-shaders/tanh.comp
@@ -16,6 +16,5 @@ void main() {
16
if (i >= p.KX) {
17
return;
18
}
19
- float th = tanh(data_a[i]);
20
- data_d[i] = D_TYPE(th==th ? th : sign(data_a[i]));
+ data_d[i] = D_TYPE(1. - 2. / (exp(2.*data_a[i]) + 1.));
21
0 commit comments