// File: /workspace/github_cpp_makefile_star2_O1/gkosae[P]ArduinoNeuralNet/neuralnet.cpp
// Function: NeuralNet::getNeuronInfo(std::__cxx11::basic_stringstream<char, std::char_traits<char>, std::allocator<char>>&)
void NeuralNet::getNeuronInfo(stringstream &ss) {
  ss << "DETAILED INFO\n";

  // print detailed info of all layers starting from the first hidden layer
  unsigned short count  = layers.size();

  for(auto i = 1; i < count; i++) {

    if(i == count - 1) ss << "Output Layer\n";
    else
        ss << "Hidden Layer " << i << '\n';

    unsigned short current_layer_size = layers.at(i).size();
    for(auto j = 0; j < current_layer_size; j++) {
      ss << "Neuron " << j+1 << ": weights ( ";

      for(auto weight : layers.at(i).neurons.at(j).weights) {
        ss << weight << " ";
      }

      ss << ") , threshold ( " << layers.at(i).neurons.at(j).threshold << " )\n";
    }

    ss << '\n';
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %rbx
movq %rdi, %r15
addq $0x10, %rbx
leaq 0x2fb8(%rip), %rsi      # 0x71f9
movl $0xe, %edx
movq %rbx, %rdi
callq 0x2190
movq 0x20(%r15), %rax
subq 0x18(%r15), %rax
sarq $0x4, %rax
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rcx, %rax
movzwl %ax, %ecx
movq %rcx, 0x10(%rsp)
cmpl $0x2, %ecx
jb 0x44b9
movq 0x10(%rsp), %rcx
decl %ecx
movq %rcx, 0x10(%rsp)
movzwl %ax, %eax
movq %rax, 0x18(%rsp)
movl $0x1, %r12d
movq %r15, 0x20(%rsp)
cmpq 0x10(%rsp), %r12
jne 0x42b0
movl $0xd, %edx
movq %rbx, %rdi
leaq 0x2f5a(%rip), %rsi      # 0x7208
jmp 0x42e1
movl $0xd, %edx
movq %rbx, %rdi
leaq 0x2f57(%rip), %rsi      # 0x7216
callq 0x2190
movq %rbx, %rdi
movl %r12d, %esi
callq 0x2250
movb $0xa, 0xe(%rsp)
movl $0x1, %edx
movq %rax, %rdi
leaq 0xe(%rsp), %rsi
callq 0x2190
movq 0x18(%r15), %rax
movq 0x20(%r15), %rdx
subq %rax, %rdx
sarq $0x4, %rdx
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rcx, %rdx
cmpq %r12, %rdx
jbe 0x44c8
leaq (%r12,%r12,2), %r14
shlq $0x4, %r14
movl 0x20(%rax,%r14), %ecx
subl 0x18(%rax,%r14), %ecx
shrl $0x6, %ecx
andl $0xffff, %ecx           # imm = 0xFFFF
je 0x4494
movl %ecx, %eax
movq %rax, 0x28(%rsp)
xorl %ebp, %ebp
movq %r12, 0x38(%rsp)
movq %r14, 0x30(%rsp)
movl $0x7, %edx
movq %rbx, %rdi
leaq 0x2ffc(%rip), %rsi      # 0x734b
callq 0x2190
leaq 0x1(%rbp), %r13
movq %rbx, %rdi
movl %r13d, %esi
callq 0x2250
movl $0xc, %edx
movq %rax, %rdi
leaq 0x2eb2(%rip), %rsi      # 0x7224
callq 0x2190
movq 0x18(%r15), %rax
movq 0x20(%r15), %rdx
subq %rax, %rdx
sarq $0x4, %rdx
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rcx, %rdx
cmpq %r12, %rdx
jbe 0x44c8
movq 0x18(%rax,%r14), %rcx
movq 0x20(%rax,%r14), %rdx
subq %rcx, %rdx
sarq $0x6, %rdx
cmpq %rbp, %rdx
jbe 0x44d4
movq %r13, 0x40(%rsp)
movq %rbp, %r13
shlq $0x6, %r13
movq 0x20(%rcx,%r13), %r15
movq 0x28(%rcx,%r13), %r12
cmpq %r12, %r15
leaq 0x2e69(%rip), %r14      # 0x7240
je 0x43ff
movsd (%r15), %xmm0
movq %rbx, %rdi
callq 0x2200
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x2190
addq $0x8, %r15
cmpq %r12, %r15
jne 0x43d9
movl $0x10, %edx
movq %rbx, %rdi
leaq 0x2e23(%rip), %rsi      # 0x7231
callq 0x2190
movq 0x20(%rsp), %r15
movq 0x18(%r15), %rax
movq 0x20(%r15), %rdx
subq %rax, %rdx
sarq $0x4, %rdx
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
imulq %rcx, %rdx
movq 0x38(%rsp), %r12
cmpq %r12, %rdx
jbe 0x44c8
movq 0x30(%rsp), %r14
movq 0x18(%rax,%r14), %rcx
movq 0x20(%rax,%r14), %rdx
subq %rcx, %rdx
sarq $0x6, %rdx
cmpq %rbp, %rdx
jbe 0x44d4
movsd 0x18(%rcx,%r13), %xmm0
movq %rbx, %rdi
callq 0x2200
movl $0x3, %edx
movq %rax, %rdi
leaq 0x2dc6(%rip), %rsi      # 0x7242
callq 0x2190
movq 0x40(%rsp), %rax
movq %rax, %rbp
cmpq 0x28(%rsp), %rax
jne 0x4340
movb $0xa, 0xf(%rsp)
movl $0x1, %edx
movq %rbx, %rdi
leaq 0xf(%rsp), %rsi
callq 0x2190
incq %r12
cmpq 0x18(%rsp), %r12
jne 0x4298
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x2be4(%rip), %rdi      # 0x70b3
movq %r12, %rsi
jmp 0x44de
leaq 0x2bd8(%rip), %rdi      # 0x70b3
movq %rbp, %rsi
xorl %eax, %eax
callq 0x21d0
nop