Re: « What's on your mind? »
Posted: 11 Jul 2018, 15:52
"One of YouTube’s many rewind offices, where employees rewind videos by hand."
rofl
rofl
Let's help each other out
https://www.autohotkey.com/boards/
As we dont share data at all we dont really have any concerns with GDPRnnnik wrote:I just noticed that we need to follow the GDPR too.
Just in case you missed the original segment on Jimmy Kimmel Live...garry wrote:Where is America ?
Code: Select all
//calculate the sigmoid of the values of the matrix mIn and put them into mOut
//to use the same matrix for input and output you can set the input to the output
void sigmoid(double* mOut, double* mIn, unsigned int w, unsigned int h) {
//using the tailor series to calculate e^x
for (unsigned int i =0; i<w*h; i++) {
double x = mIn[i];
double result = x + 1;
double dividend = x;
double divisor = 1;
for (double i=2; i<66; i++) { //we could increase precision especially for larger x by increasing the limit here
//the effect is not major or neccessary though
dividend *= x;
divisor *= i;
result += dividend/divisor;
}
mOut[i] = result/(result+1);
}
}
//calculates the derivative of sigmoid of all values of mIn and puts them into mOut
//assumes that the sigmoid function has run over the input matrix
//to use the same matrix for input and output you can set the input to the output
void sigmoidDerivative(double* mOut, double* mIn, unsigned int w, unsigned int h) {
for (unsigned int i=0; i<w*h; i++) {
double var = mIn[i];
mOut[i] = var * (1 - var);
}
}
Code: Select all
mov ecx, DWORD PTR _w$[esp-4]
imul ecx, DWORD PTR _h$[esp-4]
test ecx, ecx
je SHORT $LN3@sigmoid
mov edx, DWORD PTR _mIn$[esp-4]
mov eax, DWORD PTR _mOut$[esp-4]
sub edx, eax
movsd xmm4, QWORD PTR __real@3ff0000000000000
movsd xmm7, QWORD PTR __real@4050800000000000
npad 9
$LL4@sigmoid:
movsd xmm6, QWORD PTR [edx+eax]
movaps xmm5, xmm4
movsd xmm2, QWORD PTR __real@4000000000000000
movaps xmm1, xmm6
addsd xmm1, xmm4
movaps xmm3, xmm6
npad 6
$LL7@sigmoid:
movaps xmm0, xmm2
mulsd xmm3, xmm6
mulsd xmm5, xmm0
addsd xmm2, xmm4
movaps xmm0, xmm3
comisd xmm7, xmm2
divsd xmm0, xmm5
addsd xmm1, xmm0
ja SHORT $LL7@sigmoid
movaps xmm0, xmm1
addsd xmm0, xmm4
divsd xmm1, xmm0
movsd QWORD PTR [eax], xmm1
add eax, 8
sub ecx, 1
jne SHORT $LL4@sigmoid
$LN3@sigmoid:
; Line 18
ret 0
Code: Select all
mov ecx, DWORD PTR _w$[esp-4]
xor edx, edx
imul ecx, DWORD PTR _h$[esp-4]
push ebx
mov ebx, DWORD PTR _mOut$[esp]
push esi
mov esi, DWORD PTR _mIn$[esp+4]
mov DWORD PTR _w$[esp+4], ecx
test ecx, ecx
je $LN16@sigmoidDer
push ebp
push edi
cmp ecx, 8
jb $LN9@sigmoidDer
lea eax, DWORD PTR [esi-8]
lea eax, DWORD PTR [eax+ecx*8]
lea edi, DWORD PTR [ebx-8]
lea edi, DWORD PTR [edi+ecx*8]
cmp ebx, eax
ja SHORT $LN10@sigmoidDer
cmp edi, esi
jae $LN9@sigmoidDer
$LN10@sigmoidDer:
movaps xmm2, XMMWORD PTR __xmm@3ff00000000000003ff0000000000000
lea eax, DWORD PTR [ebx+16]
mov ebp, ecx
lea edi, DWORD PTR [esi+48]
mov ecx, esi
and ebp, -8 ; fffffff8H
sub ecx, ebx
mov DWORD PTR tv1327[esp+12], ecx
mov ecx, DWORD PTR _w$[esp+12]
mov ebx, DWORD PTR tv1327[esp+12]
$LL4@sigmoidDer:
movups xmm1, XMMWORD PTR [edi-48]
add edx, 8
movaps xmm0, xmm2
subpd xmm0, xmm1
mulpd xmm0, xmm1
movups xmm1, XMMWORD PTR [ebx+eax]
movups XMMWORD PTR [eax-16], xmm0
movaps xmm0, xmm2
subpd xmm0, xmm1
mulpd xmm0, xmm1
movups xmm1, XMMWORD PTR [edi-16]
movups XMMWORD PTR [eax], xmm0
movaps xmm0, xmm2
subpd xmm0, xmm1
mulpd xmm0, xmm1
movups xmm1, XMMWORD PTR [edi]
add edi, 64 ; 00000040H
movups XMMWORD PTR [eax+16], xmm0
movaps xmm0, xmm2
subpd xmm0, xmm1
mulpd xmm0, xmm1
movups XMMWORD PTR [eax+32], xmm0
add eax, 64 ; 00000040H
cmp edx, ebp
jb SHORT $LL4@sigmoidDer
mov ebx, DWORD PTR _mOut$[esp+12]
$LN9@sigmoidDer:
cmp edx, ecx
jae $LN22@sigmoidDer
movsd xmm2, QWORD PTR __real@3ff0000000000000
mov eax, ecx
sub eax, edx
cmp eax, 4
jb $LC17@sigmoidDer
mov eax, esi
lea ebp, DWORD PTR [esi+24]
sub eax, ebx
lea edi, DWORD PTR [edx+1]
mov DWORD PTR tv1325[esp+12], eax
lea ebp, DWORD PTR [ebp+edx*8]
mov esi, DWORD PTR tv1325[esp+12]
lea edi, DWORD PTR [ebx+edi*8]
mov eax, ecx
sub eax, edx
sub eax, 4
shr eax, 2
inc eax
lea edx, DWORD PTR [edx+eax*4]
npad 11
$LL18@sigmoidDer:
movaps xmm0, xmm2
subsd xmm0, QWORD PTR [ebp-24]
mulsd xmm0, QWORD PTR [ebp-24]
movsd QWORD PTR [edi-8], xmm0
movaps xmm0, xmm2
subsd xmm0, QWORD PTR [esi+edi]
mulsd xmm0, QWORD PTR [esi+edi]
movsd QWORD PTR [edi], xmm0
movaps xmm0, xmm2
subsd xmm0, QWORD PTR [ebp-8]
mulsd xmm0, QWORD PTR [ebp-8]
movsd QWORD PTR [edi+8], xmm0
movaps xmm0, xmm2
subsd xmm0, QWORD PTR [ebp]
mulsd xmm0, QWORD PTR [ebp]
add ebp, 32 ; 00000020H
movsd QWORD PTR [edi+16], xmm0
add edi, 32 ; 00000020H
sub eax, 1
jne SHORT $LL18@sigmoidDer
mov esi, DWORD PTR _mIn$[esp+12]
$LC17@sigmoidDer:
cmp edx, ecx
jae SHORT $LN22@sigmoidDer
sub esi, ebx
lea eax, DWORD PTR [ebx+edx*8]
sub ecx, edx
$LC8@sigmoidDer:
movaps xmm0, xmm2
subsd xmm0, QWORD PTR [esi+eax]
mulsd xmm0, QWORD PTR [esi+eax]
movsd QWORD PTR [eax], xmm0
add eax, 8
sub ecx, 1
jne SHORT $LC8@sigmoidDer
$LN22@sigmoidDer:
pop edi
pop ebp
$LN16@sigmoidDer:
pop esi
pop ebx
ret 0
Duterte drug war :Yeah, they could also keep the drugs in case some of the cops get bored and need it