// File: /workspace/github_cpp_makefile_star2_O1/theolepage[P]prophecy/src/main.cc
// Function: main
int main(void)
{
    Model<model_type> model = Model<model_type>();
    SigmoidActivationFunction s = SigmoidActivationFunction<model_type>();

    // Create model
    model.add(new InputLayer<model_type>(2));
    model.add(new DenseLayer<model_type>(2, s));
    model.add(new DenseLayer<model_type>(1, s));

    // Create dataset
    auto x_train = training_set();
    auto y_train = training_set();
    create_dataset(x_train, y_train);

    // Train model
    model.compile(0.1);
    model.train(x_train, y_train, 10000, 1);

    // Test the model
    for (size_t i = 0; i < x_train.size(); i++)
    {
        auto x = x_train.at(i);
        auto x_t = x.transpose();
        auto y = model.predict(x);
        std::cout << "Input:  " << x_t;
        std::cout << "Output: " << y << std::endl;
    }

    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1a8, %rsp            # imm = 0x1A8
leaq 0x682c(%rip), %rcx      # 0x8bc0
leaq 0x88(%rsp), %rax
movq %rcx, -0x10(%rax)
movb $0x0, -0x8(%rax)
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq $0x0, 0x10(%rax)
xorl %edi, %edi
callq 0x2120
movl %eax, %edi
callq 0x2130
leaq 0x140(%rsp), %r15
xorps %xmm0, %xmm0
movaps %xmm0, 0x10(%r15)
movaps %xmm0, (%r15)
movaps %xmm0, -0x10(%r15)
movaps %xmm0, -0x20(%r15)
leaq 0x120(%rsp), %rbx
leaq 0x38(%rsp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x38ac
movq %rbx, (%r14)
leaq 0x38(%rsp), %rsi
movq %r15, %rdi
callq 0x391a
movl $0x90, %edi
callq 0x2150
movq %rax, %rbx
movq %rax, %rdi
movl $0x2, %esi
callq 0x3d1e
leaq 0x6839(%rip), %rax      # 0x8c60
movq %rax, (%rbx)
leaq 0x38(%rsp), %rsi
movq %rbx, (%rsi)
leaq 0x88(%rsp), %rdi
callq 0x3a7c
movl $0x150, %edi            # imm = 0x150
callq 0x2150
movq %rax, %rbx
leaq 0x120(%rsp), %rdx
movq %rax, %rdi
movl $0x2, %esi
callq 0x3f86
leaq 0x6890(%rip), %r14      # 0x8cf8
movq %r14, (%rbx)
leaq 0x38(%rsp), %rsi
movq %rbx, (%rsi)
leaq 0x88(%rsp), %rdi
callq 0x3a7c
movl $0x150, %edi            # imm = 0x150
callq 0x2150
movq %rax, %rbx
leaq 0x120(%rsp), %rdx
movq %rax, %rdi
movl $0x1, %esi
callq 0x3f86
movq %r14, (%rbx)
leaq 0x38(%rsp), %rsi
movq %rbx, (%rsi)
leaq 0x88(%rsp), %rdi
callq 0x3a7c
xorl %eax, %eax
movq %rax, 0x10(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq %rax, 0x30(%rsp)
movaps %xmm0, 0x20(%rsp)
leaq 0x38(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x2991
movq %rsp, %rdi
leaq 0x38(%rsp), %rsi
callq 0x3202
leaq 0x58(%rsp), %rsi
leaq 0x20(%rsp), %rdi
callq 0x3202
leaq 0xa0(%rsp), %rdi
xorl %esi, %esi
movl $0x1, %edx
callq 0x2991
movq %rsp, %rdi
leaq 0xa0(%rsp), %rsi
callq 0x3202
leaq 0xc0(%rsp), %rsi
leaq 0x20(%rsp), %rdi
callq 0x3202
leaq 0xe0(%rsp), %rdi
movl $0x1, %esi
xorl %edx, %edx
callq 0x2991
movq %rsp, %rdi
leaq 0xe0(%rsp), %rsi
callq 0x3202
leaq 0x100(%rsp), %rsi
leaq 0x20(%rsp), %rdi
callq 0x3202
leaq 0x168(%rsp), %rdi
movl $0x1, %esi
movl $0x1, %edx
callq 0x2991
movq %rsp, %rdi
leaq 0x168(%rsp), %rsi
callq 0x3202
leaq 0x188(%rsp), %rsi
leaq 0x20(%rsp), %rdi
callq 0x3202
leaq 0x6538(%rip), %r15      # 0x8ae0
movq %r15, 0x188(%rsp)
movq 0x1a0(%rsp), %rdi
testq %rdi, %rdi
je 0x25c2
callq 0x349c
movq %r15, 0x168(%rsp)
movq 0x180(%rsp), %rdi
testq %rdi, %rdi
je 0x25dc
callq 0x349c
movq %r15, 0x100(%rsp)
movq 0x118(%rsp), %rdi
testq %rdi, %rdi
je 0x25f6
callq 0x349c
movq %r15, 0xe0(%rsp)
movq 0xf8(%rsp), %rdi
testq %rdi, %rdi
je 0x2610
callq 0x349c
movq %r15, 0xc0(%rsp)
movq 0xd8(%rsp), %rdi
testq %rdi, %rdi
je 0x262a
callq 0x349c
movq %r15, 0xa0(%rsp)
movq 0xb8(%rsp), %rdi
testq %rdi, %rdi
je 0x2644
callq 0x349c
movq %r15, 0x58(%rsp)
movq 0x70(%rsp), %rdi
testq %rdi, %rdi
je 0x2658
callq 0x349c
movq %r15, 0x38(%rsp)
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x266c
callq 0x349c
leaq 0x78(%rsp), %rdi
movss 0x398b(%rip), %xmm0     # 0x6004
callq 0x2ad6
leaq 0x78(%rsp), %rdi
movq %rsp, %rsi
leaq 0x20(%rsp), %rdx
movl $0x2710, %ecx           # imm = 0x2710
movl $0x1, %r8d
callq 0x2dde
movq (%rsp), %r14
cmpq %r14, 0x8(%rsp)
je 0x27ff
movl $0x18, %r12d
xorl %r13d, %r13d
leaq 0xe0(%rsp), %rbp
movq 0x6906(%rip), %rbx      # 0x8fc8
movq %r15, 0x38(%rsp)
leaq 0x48(%rsp), %rax
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
leaq (%r14,%r12), %rsi
movq -0x8(%r14,%r12), %rax
movq %rax, 0x48(%rsp)
leaq 0x50(%rsp), %rdi
callq 0x3866
movl -0x10(%r14,%r12), %eax
movl %eax, 0x40(%rsp)
movl -0xc(%r14,%r12), %eax
movl %eax, 0x44(%rsp)
leaq 0xa0(%rsp), %rdi
leaq 0x38(%rsp), %r14
movq %r14, %rsi
callq 0x3010
movq 0x88(%rsp), %rax
movq (%rax), %rsi
movq (%rsi), %rax
movq %rbp, %rdi
movq %r14, %rdx
xorl %ecx, %ecx
callq *0x10(%rax)
movl $0x8, %edx
movq %rbx, %rdi
leaq 0x390f(%rip), %rsi      # 0x6048
callq 0x2180
movq %rbx, %rdi
leaq 0xa0(%rsp), %rsi
callq 0x30a7
movl $0x8, %edx
movq %rbx, %rdi
leaq 0x38f4(%rip), %rsi      # 0x6051
callq 0x2180
movq %rbx, %rdi
movq %rbp, %rsi
callq 0x30a7
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x2140
movsbl %al, %esi
movq %r14, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x20e0
movq %r15, 0xe0(%rsp)
movq 0xf8(%rsp), %rdi
testq %rdi, %rdi
je 0x27b1
callq 0x349c
movq %r15, 0xa0(%rsp)
movq 0xb8(%rsp), %rdi
testq %rdi, %rdi
je 0x27cb
callq 0x349c
movq %r15, 0x38(%rsp)
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x27df
callq 0x349c
incq %r13
movq (%rsp), %r14
movq 0x8(%rsp), %rax
subq %r14, %rax
sarq $0x5, %rax
addq $0x20, %r12
cmpq %rax, %r13
jb 0x26c2
leaq 0x20(%rsp), %rdi
callq 0x31ac
movq %rsp, %rdi
callq 0x31ac
movq 0x150(%rsp), %rax
testq %rax, %rax
je 0x2830
leaq 0x140(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
movq 0x130(%rsp), %rax
testq %rax, %rax
je 0x284f
leaq 0x120(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0x636a(%rip), %rax      # 0x8bc0
movq %rax, 0x78(%rsp)
leaq 0x88(%rsp), %rdi
callq 0x37f8
xorl %eax, %eax
addq $0x1a8, %rsp            # imm = 0x1A8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x287e
movq %rax, %rdi
callq 0x3428
jmp 0x28bf
jmp 0x28d1
jmp 0x28e3
jmp 0x288e
movq %rax, %r14
movl $0x150, %esi            # imm = 0x150
jmp 0x28a0
movq %rax, %r14
movl $0x90, %esi
movq %rbx, %rdi
callq 0x2160
jmp 0x2963
movq %rax, %r14
leaq 0x168(%rsp), %rdi
callq 0x3272
jmp 0x28c2
movq %rax, %r14
leaq 0xe0(%rsp), %rdi
callq 0x3272
jmp 0x28d4
movq %rax, %r14
leaq 0xa0(%rsp), %rdi
callq 0x3272
jmp 0x28e6
movq %rax, %r14
leaq 0x38(%rsp), %rdi
callq 0x3272
jmp 0x2951
movq %rax, %r14
jmp 0x2951
movq %rax, %r14
jmp 0x2963
movq %rax, %r14
jmp 0x293d
movq %rax, %r14
jmp 0x2923
movq %rax, %r14
movq %r15, 0xe0(%rsp)
movq 0xf8(%rsp), %rdi
testq %rdi, %rdi
je 0x2923
callq 0x349c
movq %r15, 0xa0(%rsp)
movq 0xb8(%rsp), %rdi
testq %rdi, %rdi
je 0x293d
callq 0x349c
movq %r15, 0x38(%rsp)
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x2951
callq 0x349c
leaq 0x20(%rsp), %rdi
callq 0x31ac
movq %rsp, %rdi
callq 0x31ac
leaq 0x120(%rsp), %rdi
callq 0x4b7c
leaq 0x6249(%rip), %rax      # 0x8bc0
movq %rax, 0x78(%rsp)
leaq 0x88(%rsp), %rdi
callq 0x37f8
movq %r14, %rdi
callq 0x2200