Skip to content

Commit 39b1755

Browse files
committed
fix: always pass bias arg in zero3_linear_wrap to avoid setup_context unpack error
Signed-off-by: Sung Hyun Cho <hope5487@gmail.com>
1 parent 33db7c4 commit 39b1755

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

deepspeed/runtime/zero/linear.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -154,10 +154,7 @@ def backward(ctx, grad_output):
154154

155155

156156
def zero3_linear_wrap(input, weight, bias=None):
157-
if bias is None:
158-
return LinearFunctionForZeroStage3.apply(input, weight)
159-
else:
160-
return LinearFunctionForZeroStage3.apply(input, weight, bias)
157+
return LinearFunctionForZeroStage3.apply(input, weight, bias)
161158

162159

163160
class LinearModuleForZeroStage3(Module):

0 commit comments

Comments
 (0)