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
bitsandbytes
Commits
eac9aca4
"git@developer.sourcefind.cn:OpenDAS/mmcv.git" did not exist on "1e922b84eed0e2bdb138564c70a5d905d5155bf4"
Commit
eac9aca4
authored
Sep 17, 2022
by
justheuristic
Browse files
cast bias too
parent
a9fe0ff9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
bitsandbytes/autograd/_functions.py
bitsandbytes/autograd/_functions.py
+2
-0
No files found.
bitsandbytes/autograd/_functions.py
View file @
eac9aca4
...
@@ -234,6 +234,8 @@ class MatMul8bitLt(torch.autograd.Function):
...
@@ -234,6 +234,8 @@ class MatMul8bitLt(torch.autograd.Function):
if
A_dtype
!=
torch
.
float16
:
if
A_dtype
!=
torch
.
float16
:
warnings
.
warn
(
f
"MatMul8bitLt: input matrix will be converted from
{
A_dtype
}
to float16"
)
warnings
.
warn
(
f
"MatMul8bitLt: input matrix will be converted from
{
A_dtype
}
to float16"
)
A
=
A
.
to
(
torch
.
float16
)
A
=
A
.
to
(
torch
.
float16
)
if
bias
is
not
None
:
bias
=
bias
.
to
(
torch
.
float16
)
# 1. Quantize A
# 1. Quantize A
if
len
(
A
.
shape
)
==
3
:
if
len
(
A
.
shape
)
==
3
:
...
...
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