Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
TransformerEngine
Commits
45e9d8b6
Unverified
Commit
45e9d8b6
authored
Feb 14, 2025
by
Phuong Nguyen
Committed by
GitHub
Feb 14, 2025
Browse files
[JAX] Lint Fix (#1484)
JAX Lint Fix Signed-off-by:
Phuong Nguyen
<
phuonguyen@nvidia.com
>
parent
e19b8281
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
3 deletions
+1
-3
transformer_engine/jax/flax/module.py
transformer_engine/jax/flax/module.py
+0
-1
transformer_engine/jax/flax/transformer.py
transformer_engine/jax/flax/transformer.py
+1
-2
No files found.
transformer_engine/jax/flax/module.py
View file @
45e9d8b6
...
...
@@ -1251,7 +1251,6 @@ class LayerNormMLP(TransformerEngineBase):
# Remove act axis
z
=
jnp
.
reshape
(
z
,
(
*
z
.
shape
[:
-
2
],
-
1
))
z
=
z
.
astype
(
self
.
dtype
)
# import pdb; pdb.set_trace()
z
=
nn
.
Dropout
(
rate
=
self
.
intermediate_dropout_rate
,
...
...
transformer_engine/jax/flax/transformer.py
View file @
45e9d8b6
...
...
@@ -987,9 +987,8 @@ class MultiHeadAttention(nn.Module): # pylint: disable=too-few-public-methods
if
self
.
kernel_init
is
None
:
self
.
kernel_init
=
nn
.
initializers
.
variance_scaling
(
1.0
,
"fan_in"
,
"normal"
,
self
.
weight_dtype
1.0
,
"fan_in"
,
"normal"
,
dtype
=
self
.
weight_dtype
)
self
.
kernel_init
=
_kernel_init
.
astype
(
self
.
dtype
)
if
self
.
num_gqa_groups
is
None
:
self
.
num_gqa_groups
=
self
.
num_attention_heads
super
().
__post_init__
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment