// File: /workspace/github_cpp_makefile_star2_O1/godofecht[P]Slow-Feature-Analysis/./sfa.h
// Function: SFA::SFA(float, int)
SFA(float RO, int num_invariances)
    {
        ro = RO;
        TOTAL_TIME = 50*ro;


        NUM_INVARIANCES = num_invariances;
        
        if(NUM_INVARIANCES == 1)
        {
            NUM_INPUT_NEURONS_Y = 1;
            NUM_INPUT_NEURONS_X = 101;

            lambda_long = 2.0f * ro;
            lambda_short = ro/31.0f;
            gamma_long = pow(0.5f,(1.0f/(lambda_long)));
            gamma_short = pow(0.5f,(1.0f/(lambda_short)));

            y_tilde = 0.0f;
            y_bar = 0.0f;
            U = 0.000f;
            V = 0.000f;


            vector<unsigned> a;
            a.push_back(NUM_INPUT_NEURONS_X);
            a.push_back(1);
            SetTopology(a);
            InitializeTopology();

            for(int i=0;i<NUM_INPUT_NEURONS_X;i++)
            {
                x_bar_vector.push_back(0.0f);
                x_tilde_vector.push_back(0.0f);
                del_weight_vector.push_back(0.0f);
                input_vector.push_back(0.0f);
            }
/*

            lambda_long = 2.0f * ro;
            lambda_short = ro/31.0f;
            gamma_long = pow(0.5f,(1.0f/(lambda_long)));
            gamma_short = pow(0.5f,(1.0f/(lambda_short)));

            y_tilde = 0.0f;
            y_bar = 0.0f;
            U = 0.000f;
            V = 0.000f;

            vector<unsigned> a;
            a.push_back(NUM_INPUT_NEURONS_X);
            a.push_back(1);
            SetTopology(a);
            InitializeTopology();

            for(int i=0;i<NUM_INPUT_NEURONS_X;i++)
            {
                x_bar_vector.push_back(0.0f);
                x_tilde_vector.push_back(0.0f);
                del_weight_vector.push_back(0.0f);
                input_vector.push_back(0.0f);
            }

*/
        }
        else if(NUM_INVARIANCES == 2)
        {
            NUM_INPUT_NEURONS_Y = 51;
            NUM_INPUT_NEURONS_X = 51;

            lambda_long = 2.0f * ro;
            lambda_short = ro/31.0f;
            gamma_long = pow(0.5f,(1.0f/(lambda_long)));
            gamma_short = pow(0.5f,(1.0f/(lambda_short)));

            y1_tilde = 0.0f;
            y1_bar = 0.0f;
            y2_tilde = 0.0f;
            y2_bar = 0.0f;
            U1 = 0.000f;
            U2 = 0.0f;
            V1 = 0.0f;
            V2 = 0.0f;

            y1 = 0.0f;
            y2 = 0.0f;


            vector<unsigned> a;
            a.push_back(NUM_INPUT_NEURONS_X * NUM_INPUT_NEURONS_Y);
            a.push_back(2);
            SetTopology(a);
            InitializeTopology();

            for(int i=0;i<NUM_INPUT_NEURONS_X * NUM_INPUT_NEURONS_Y;i++)
            {
                x_bar_vector.push_back(0.0f);
                x_tilde_vector.push_back(0.0f);
                del_weight_vector.push_back(0.0f);
                del_weight1_vector.push_back(0.0f);
                del_weight2_vector.push_back(0.0f);
                input_vector.push_back(0.0f);
            }
        }


        cout<<"finished constructing"<<endl;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movl %esi, %r14d
movss %xmm0, -0x6c(%rbp)
movq %rdi, %rbx
leaq 0x8(%rdi), %r13
xorps %xmm0, %xmm0
movups %xmm0, 0x58(%rdi)
movups %xmm0, 0x48(%rdi)
movups %xmm0, 0x38(%rdi)
movups %xmm0, 0x28(%rdi)
movups %xmm0, 0x18(%rdi)
movups %xmm0, 0x8(%rdi)
movabsq $0x3f50624de0000000, %rax # imm = 0x3F50624DE0000000
movq %rax, 0x68(%rdi)
leaq 0x70(%rdi), %rdi
leaq 0x90(%rbx), %r12
leaq 0xa8(%rbx), %rax
movq %rax, -0x68(%rbp)
leaq 0xc0(%rbx), %rax
movq %rax, -0x60(%rbp)
leaq 0xd8(%rbx), %rax
movq %rax, -0x80(%rbp)
leaq 0xf0(%rbx), %rax
movq %rax, -0x78(%rbp)
leaq 0x108(%rbx), %rax
movq %rax, -0x58(%rbp)
xorl %r15d, %r15d
movl $0xe0, %edx
xorl %esi, %esi
callq 0x20e0
movl $0x1, 0x1c8(%rbx)
movabsq $0x407c200000000000, %rax # imm = 0x407C200000000000
movq %rax, 0x1d0(%rbx)
leaq 0x1e0(%rbx), %rdi
movl $0xa9, %edx
movq %rdi, -0x88(%rbp)
xorl %esi, %esi
callq 0x20e0
movb $0x1, 0x289(%rbx)
movq %r15, 0x290(%rbx)
xorps %xmm0, %xmm0
cvtss2sd -0x6c(%rbp), %xmm0
xorps %xmm1, %xmm1
movups %xmm1, 0x2a0(%rbx)
movups %xmm1, 0x2b0(%rbx)
movups %xmm1, 0x2c0(%rbx)
movups %xmm1, 0x2d0(%rbx)
movups %xmm1, 0x2e0(%rbx)
movups %xmm1, 0x2f0(%rbx)
movups %xmm1, 0x300(%rbx)
movq %r15, 0x310(%rbx)
movsd 0x35f9(%rip), %xmm1     # 0x7028
mulsd %xmm0, %xmm1
cvttsd2si %xmm1, %eax
movsd %xmm0, 0x1d0(%rbx)
movl %eax, 0x1d8(%rbx)
movl %r14d, 0x298(%rbx)
cmpl $0x2, %r14d
je 0x3b08
cmpl $0x1, %r14d
jne 0x3f5a
leaq 0x1c0(%rbx), %r14
movabsq $0x100000065, %rax      # imm = 0x100000065
movq %rax, 0x1c0(%rbx)
movapd %xmm0, %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, 0x80(%rbx)
divsd 0x35a0(%rip), %xmm0     # 0x7030
movsd %xmm0, 0x88(%rbx)
movsd 0x3570(%rip), %xmm0     # 0x7010
divsd %xmm1, %xmm0
callq 0x2180
movsd %xmm0, 0x70(%rbx)
movsd 0x355a(%rip), %xmm0     # 0x7010
divsd 0x88(%rbx), %xmm0
callq 0x2180
movsd %xmm0, 0x78(%rbx)
xorpd %xmm0, %xmm0
movupd %xmm0, 0x150(%rbx)
movupd %xmm0, 0x160(%rbx)
movapd %xmm0, -0x50(%rbp)
movq $0x0, -0x40(%rbp)
movq -0x48(%rbp), %rsi
testq %rsi, %rsi
je 0x3bc7
movl (%r14), %eax
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, -0x48(%rbp)
jmp 0x3bd3
movabsq $0x3300000033, %rax     # imm = 0x3300000033
movq %rax, 0x1c0(%rbx)
movapd %xmm0, %xmm1
addsd %xmm0, %xmm1
movsd %xmm1, 0x80(%rbx)
divsd 0x34ff(%rip), %xmm0     # 0x7030
movsd %xmm0, 0x88(%rbx)
movsd 0x34cf(%rip), %xmm0     # 0x7010
divsd %xmm1, %xmm0
callq 0x2180
movsd %xmm0, 0x70(%rbx)
movsd 0x34b9(%rip), %xmm0     # 0x7010
divsd 0x88(%rbx), %xmm0
callq 0x2180
movsd %xmm0, 0x78(%rbx)
xorpd %xmm0, %xmm0
movupd %xmm0, 0x170(%rbx)
movupd %xmm0, 0x180(%rbx)
movupd %xmm0, 0x190(%rbx)
movupd %xmm0, 0x1a0(%rbx)
movupd %xmm0, 0x1b0(%rbx)
movapd %xmm0, -0x50(%rbp)
movq $0x0, -0x40(%rbp)
movl 0x1c4(%rbx), %eax
imull 0x1c0(%rbx), %eax
movl %eax, -0x30(%rbp)
movq -0x48(%rbp), %rsi
testq %rsi, %rsi
je 0x3bf4
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, -0x48(%rbp)
jmp 0x3c01
leaq -0x50(%rbp), %rdi
movq %r14, %rdx
callq 0x4e6e
movl $0x1, -0x30(%rbp)
movq -0x48(%rbp), %rsi
cmpq -0x40(%rbp), %rsi
je 0x3c29
movl $0x1, (%rsi)
addq $0x4, %rsi
movq %rsi, -0x48(%rbp)
jmp 0x3c36
leaq -0x50(%rbp), %rdi
leaq -0x30(%rbp), %rdx
callq 0x4fb4
movl $0x2, -0x30(%rbp)
movq -0x48(%rbp), %rsi
cmpq -0x40(%rbp), %rsi
je 0x3d83
movl $0x2, (%rsi)
addq $0x4, %rsi
movq %rsi, -0x48(%rbp)
jmp 0x3d90
leaq -0x50(%rbp), %rdi
leaq -0x30(%rbp), %rdx
callq 0x4fb4
leaq -0xb8(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x4d82
leaq -0xb8(%rbp), %rsi
movq %r13, %rdi
callq 0x5088
movq -0xb8(%rbp), %rdi
testq %rdi, %rdi
je 0x3c66
callq 0x21a0
movq %rbx, %rdi
callq 0x4e02
movq %r12, %r13
cmpl $0x0, (%r14)
je 0x3d6d
xorl %r12d, %r12d
leaq -0x30(%rbp), %r15
movq $0x0, -0x30(%rbp)
movq 0xb0(%rbx), %rsi
cmpq 0xb8(%rbx), %rsi
je 0x3cae
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xb0(%rbx)
jmp 0x3cba
movq -0x68(%rbp), %rdi
movq %r15, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0x98(%rbx), %rsi
cmpq 0xa0(%rbx), %rsi
je 0x3ce6
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x98(%rbx)
jmp 0x3cf1
movq %r13, %rdi
movq %r15, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0xc8(%rbx), %rsi
cmpq 0xd0(%rbx), %rsi
je 0x3d1d
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xc8(%rbx)
jmp 0x3d29
movq -0x60(%rbp), %rdi
movq %r15, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0x110(%rbx), %rsi
cmpq 0x118(%rbx), %rsi
je 0x3d55
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x110(%rbx)
jmp 0x3d61
movq -0x58(%rbp), %rdi
movq %r15, %rdx
callq 0x6696
incl %r12d
cmpl (%r14), %r12d
jb 0x3c82
movq -0x50(%rbp), %rdi
testq %rdi, %rdi
je 0x3d7b
callq 0x21a0
movq %r13, %r12
jmp 0x3f5a
leaq -0x50(%rbp), %rdi
leaq -0x30(%rbp), %rdx
callq 0x4fb4
leaq -0xa0(%rbp), %rdi
leaq -0x50(%rbp), %rsi
callq 0x4d82
leaq -0xa0(%rbp), %rsi
movq %r13, %rdi
callq 0x5088
movq -0xa0(%rbp), %rdi
testq %rdi, %rdi
je 0x3dc0
callq 0x21a0
movq %rbx, %rdi
callq 0x4e02
movl 0x1c4(%rbx), %eax
imull 0x1c0(%rbx), %eax
testl %eax, %eax
je 0x3f4c
xorl %r15d, %r15d
leaq -0x30(%rbp), %r14
movq $0x0, -0x30(%rbp)
movq 0xb0(%rbx), %rsi
cmpq 0xb8(%rbx), %rsi
je 0x3e10
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xb0(%rbx)
jmp 0x3e1c
movq -0x68(%rbp), %rdi
movq %r14, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0x98(%rbx), %rsi
cmpq 0xa0(%rbx), %rsi
je 0x3e48
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x98(%rbx)
jmp 0x3e53
movq %r12, %rdi
movq %r14, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0xc8(%rbx), %rsi
cmpq 0xd0(%rbx), %rsi
je 0x3e7f
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xc8(%rbx)
jmp 0x3e8b
movq -0x60(%rbp), %rdi
movq %r14, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0xe0(%rbx), %rsi
cmpq 0xe8(%rbx), %rsi
je 0x3eb7
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xe0(%rbx)
jmp 0x3ec3
movq -0x80(%rbp), %rdi
movq %r14, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0xf8(%rbx), %rsi
cmpq 0x100(%rbx), %rsi
je 0x3eef
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0xf8(%rbx)
jmp 0x3efb
movq -0x78(%rbp), %rdi
movq %r14, %rdx
callq 0x6696
movq $0x0, -0x30(%rbp)
movq 0x110(%rbx), %rsi
cmpq 0x118(%rbx), %rsi
je 0x3f27
movq $0x0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x110(%rbx)
jmp 0x3f33
movq -0x58(%rbp), %rdi
movq %r14, %rdx
callq 0x6696
incl %r15d
movl 0x1c4(%rbx), %eax
imull 0x1c0(%rbx), %eax
cmpl %eax, %r15d
jb 0x3de4
movq -0x50(%rbp), %rdi
testq %rdi, %rdi
je 0x3f5a
callq 0x21a0
movq 0x6077(%rip), %r14      # 0x9fd8
leaq 0x3199(%rip), %rsi      # 0x7101
movl $0x15, %edx
movq %r14, %rdi
callq 0x21f0
movq (%r14), %rax
addq -0x18(%rax), %r14
movq %r14, %rdi
movl $0xa, %esi
callq 0x21c0
movsbl %al, %esi
movq 0x6045(%rip), %rdi      # 0x9fd8
callq 0x2030
movq %rax, %rdi
callq 0x2100
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x3ff2
jmp 0x3ff2
jmp 0x3ff2
movq %r12, %r13
movq %rax, %r15
movq -0xa0(%rbp), %rdi
jmp 0x3fd4
movq %r12, %r13
movq %rax, %r15
movq -0xb8(%rbp), %rdi
testq %rdi, %rdi
je 0x3ff8
callq 0x21a0
jmp 0x3ff8
jmp 0x3ff2
jmp 0x3ff2
jmp 0x3ff2
jmp 0x3ff2
jmp 0x3ff2
jmp 0x3ff5
jmp 0x3ff2
jmp 0x3ff2
jmp 0x3ff5
movq %r12, %r13
movq %rax, %r15
movq -0x50(%rbp), %rdi
testq %rdi, %rdi
je 0x4012
callq 0x21a0
jmp 0x4012
jmp 0x3ff5
jmp 0x3ff5
movq %r12, %r13
movq %rax, %r15
movq 0x300(%rbx), %rdi
testq %rdi, %rdi
je 0x4023
callq 0x21a0
movq 0x2e8(%rbx), %rdi
testq %rdi, %rdi
je 0x4034
callq 0x21a0
movq 0x2d0(%rbx), %rdi
testq %rdi, %rdi
je 0x4045
callq 0x21a0
leaq 0x2a0(%rbx), %r14
movq 0x2b8(%rbx), %rdi
testq %rdi, %rdi
je 0x405d
callq 0x21a0
movq (%r14), %rdi
testq %rdi, %rdi
je 0x406a
callq 0x21a0
movq 0x270(%rbx), %rdi
testq %rdi, %rdi
je 0x407b
callq 0x21a0
movq 0x258(%rbx), %rdi
testq %rdi, %rdi
je 0x408c
callq 0x21a0
movq 0x240(%rbx), %rdi
testq %rdi, %rdi
je 0x409d
callq 0x21a0
movq 0x228(%rbx), %rdi
testq %rdi, %rdi
je 0x40ae
callq 0x21a0
movq 0x210(%rbx), %rdi
testq %rdi, %rdi
je 0x40bf
callq 0x21a0
movq 0x1f8(%rbx), %rdi
testq %rdi, %rdi
je 0x40d0
callq 0x21a0
movq -0x88(%rbp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x40e4
callq 0x21a0
movq 0x138(%rbx), %rdi
testq %rdi, %rdi
je 0x40f5
callq 0x21a0
movq 0x120(%rbx), %rdi
testq %rdi, %rdi
je 0x4106
callq 0x21a0
movq -0x58(%rbp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x4117
callq 0x21a0
movq -0x78(%rbp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x4128
callq 0x21a0
movq -0x80(%rbp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x4139
callq 0x21a0
movq -0x60(%rbp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x414a
callq 0x21a0
movq -0x68(%rbp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x415b
callq 0x21a0
movq (%r13), %rdi
testq %rdi, %rdi
je 0x4169
callq 0x21a0
movq 0x50(%rbx), %rdi
testq %rdi, %rdi
je 0x4177
callq 0x21a0
movq 0x38(%rbx), %rdi
testq %rdi, %rdi
je 0x4185
callq 0x21a0
movq %rbx, %rdi
callq 0x4e40
movq %r15, %rdi
callq 0x2290
nop