Skip to content
This repository has been archived by the owner on Aug 7, 2024. It is now read-only.

Commit

Permalink
revert change to scale dtype as it seems to work now
Browse files Browse the repository at this point in the history
  • Loading branch information
ani300 committed Jun 20, 2024
1 parent eec175a commit 35a5dfc
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion float8_experimental/float8_ops.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ def decorator(func):
aten.slice.Tensor,
aten.transpose.int,
aten.fill_.Scalar,
aten.copy_.default,
]
)
def float8_desugar_op(aten_op, args, kwargs=None):
Expand Down
2 changes: 1 addition & 1 deletion float8_experimental/float8_tensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ class FromFloat8ConstrFunc(torch.autograd.Function):

@staticmethod
def forward(ctx, tensor):
return (tensor._data.to(tensor._orig_dtype) / tensor._scale.to(tensor._org_dtype))
return tensor._data.to(tensor._orig_dtype) / tensor._scale

@staticmethod
def backward(ctx, g):
Expand Down

0 comments on commit 35a5dfc

Please sign in to comment.