Skip to content

Commit f221ee9

Browse files
racinmatToucheSir
andauthored
Update src/onehot.jl
Co-authored-by: Brian Chen <ToucheSir@users.noreply.github.com>
1 parent 7ce132f commit f221ee9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/onehot.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ end
229229
function Base.:(*)(A::AbstractMatrix, B::Adjoint{Bool, <:OneHotMatrix})
230230
B_dim = length(parent(B).indices)
231231
size(A, 2) == B_dim || throw(DimensionMismatch("Matrix column must correspond with OneHot size: $(size(A, 2)) != $B_dim"))
232-
return NNlib.scatter(+, A, parent(B).indices, dstsize=(size(A,1), size(B,2)))
232+
return NNlib.scatter(+, A, _indices(parent(B)), dstsize=(size(A,1), size(B,2)))
233233
end
234234

235235
for wrapper in [:Adjoint, :Transpose]

0 commit comments

Comments
 (0)