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
5d658171
Commit
5d658171
authored
Sep 18, 2022
by
justheuristic
Browse files
debug
parent
4da2227f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
bitsandbytes/autograd/_functions.py
bitsandbytes/autograd/_functions.py
+0
-2
bitsandbytes/nn/modules.py
bitsandbytes/nn/modules.py
+3
-1
No files found.
bitsandbytes/autograd/_functions.py
View file @
5d658171
...
@@ -370,8 +370,6 @@ class MatMul8bitLt(torch.autograd.Function):
...
@@ -370,8 +370,6 @@ class MatMul8bitLt(torch.autograd.Function):
if
state
.
threshold
>
0.0
and
subA
is
not
None
:
if
state
.
threshold
>
0.0
and
subA
is
not
None
:
grad_B
[:,
idx
]
+=
torch
.
matmul
(
grad_output
.
t
(),
subA
)
grad_B
[:,
idx
]
+=
torch
.
matmul
(
grad_output
.
t
(),
subA
)
raise
NotImplementedError
(
"!!"
)
if
req_gradA
:
if
req_gradA
:
if
state
.
CBt
is
not
None
:
if
state
.
CBt
is
not
None
:
C32grad
,
Sgrad
=
F
.
transform
(
Cgrad
,
"col32"
)
C32grad
,
Sgrad
=
F
.
transform
(
Cgrad
,
"col32"
)
...
...
bitsandbytes/nn/modules.py
View file @
5d658171
...
@@ -237,7 +237,9 @@ class Linear8bitLt(nn.Linear):
...
@@ -237,7 +237,9 @@ class Linear8bitLt(nn.Linear):
if
threshold
>
0.0
and
not
has_fp16_weights
:
if
threshold
>
0.0
and
not
has_fp16_weights
:
self
.
state
.
use_pool
=
True
self
.
state
.
use_pool
=
True
self
.
weight
=
Int8Params
(
self
.
weight
.
data
,
has_fp16_weights
=
has_fp16_weights
)
self
.
weight
=
Int8Params
(
self
.
weight
.
data
,
has_fp16_weights
=
has_fp16_weights
,
requires_grad
=
has_fp16_weights
)
def
init_8bit_state
(
self
):
def
init_8bit_state
(
self
):
self
.
state
.
CB
=
self
.
weight
.
CB
self
.
state
.
CB
=
self
.
weight
.
CB
...
...
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