Last active
December 22, 2015 20:09
-
-
Save 9il/6524193 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sgemm(Order.RowMajor, Transpose.NoTrans, Transpose.NoTrans, | |
dl, wl, tl, 1.0, pdt.ptr, tl, ptw.ptr, wl, 0.0, qdw.ptr, wl); | |
qdw.array[] /= ndw.array[]; | |
sgemm(Order.RowMajor, Transpose. Trans, Transpose.NoTrans, | |
tl, wl, dl, 1.0, pdt.ptr, tl, qdw.ptr, wl, 0.0, rtw.ptr, wl); | |
rtw.array[] *= ptw.array[]; | |
sgemm(Order.RowMajor, Transpose.NoTrans, Transpose. Trans, | |
dl, tl, wl, 1.0, qdw.ptr, wl, ptw.ptr, wl, 0.0, rdt.ptr, tl); | |
rdt.array[] *= pdt.array[]; | |
for(auto a = ptw, b = rtw; !a.empty; a.popFront, b.popFront) | |
a.front[] = b.front[] / b.front.sum; | |
for(auto a = pdt, b = rdt; !a.empty; a.popFront, b.popFront) | |
a.front[] = b.front[] / b.front.sum; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment