// File: xbai0624[P]dnn/src/ConstructLayer.cpp
// Function: ConstructLayer::Print()
void ConstructLayer::Print()
{
    // layer id
    std::cout<<"----------- Layer ID: "<<GetID()<<" ------------"<<std::endl;
    // layer type
    if(__type == LayerType::cnn )std::cout<<"layer type: cnn"<<std::endl;
    else if(__type == LayerType::fullyConnected) std::cout<<"layer type: FC"<<std::endl;
    // drop out factor
    std::cout<<"drop out factor: "<<__dropOut<<std::endl;
    std::cout<<"use drop out: "<<__use_drop_out<<std::endl;
    if(__type == LayerType::fullyConnected)
        std::cout<<"number of fc neurons: "<<__n_neurons_fc<<std::endl;
    if(__type == LayerType::cnn)
    {
        std::cout<<"number of cnn kernels: "<<__n_kernels_cnn<<std::endl;
        std::cout<<"kernel  dimension: "<<__kernelDim<<std::endl;
    }
    // weight matrix
    std::cout<<" --- w&b "<<std::endl;
    for(size_t i=0;i<__weightMatrix.size();i++)
    {
        std::cout<<"weight matrix : "<<i<<std::endl;
        std::cout<<__weightMatrix[i]<<std::endl;
        std::cout<<"bias matrix: "<<i<<std::endl;
        std::cout<<__biasVector[i]<<std::endl;
    }
    // drop out filter
    std::cout<<" --- active flag matrix "<<std::endl;
    for(size_t i=0;i<__activeFlag.size();i++)
    {
        std::cout<<"active flag : "<<i<<std::endl;
        std::cout<<__activeFlag[i]<<std::endl;
    }

    // active weight matrix
    std::cout<<" --- active w&b "<<std::endl;
    for(size_t i=0;i<__weightMatrixActive.size();i++)
    {
        std::cout<<"active weight matrix : "<<i<<std::endl;
        std::cout<<__weightMatrixActive[i]<<std::endl;
        std::cout<<"active bias matrix: "<<i<<std::endl;
        std::cout<<__biasVectorActive[i]<<std::endl;
    }

    std::cout<<std::endl<<"==================================="<<std::endl;
    std::cout<<" --- neuron information: "<<std::endl;
    for(size_t ii=0;ii<__neurons.size();ii++)
    {
        auto __neuron_dimension = __neurons[ii].Dimension();
        std::cout<<"Neruon Matrix Dimension: "<<__neuron_dimension<<std::endl;

        for(size_t i=0;i<__neuron_dimension.first;i++)
        {
            for(size_t j=0;j<__neuron_dimension.second;j++)
            {
                std::cout<<"coord:  ("<<i<<", "<<j<<")"<<std::endl;
                __neurons[ii][i][j]->Print();
            }
        }
    }
}

// Assembly:
subq $0x78, %rsp
movq %rdi, 0x70(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0x4f58e(%rip), %rdi     # 0x6afd8
leaq 0x38411(%rip), %rsi     # 0x53e62
callq 0x4230
movq 0x28(%rsp), %rdi
movq %rax, 0x20(%rsp)
movq (%rdi), %rax
callq *0x298(%rax)
movq 0x20(%rsp), %rdi
movl %eax, %esi
callq 0x43e0
movq %rax, %rdi
leaq 0x383fa(%rip), %rsi     # 0x53e79
callq 0x4230
movq %rax, %rdi
movq 0x4f522(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rax
cmpl $0x1, 0xc(%rax)
jne 0x1bac2
movq 0x4f533(%rip), %rdi     # 0x6afd8
leaq 0x383db(%rip), %rsi     # 0x53e87
callq 0x4230
movq %rax, %rdi
movq 0x4f4f5(%rip), %rsi     # 0x6afb0
callq 0x4260
jmp 0x1baf1
movq 0x28(%rsp), %rax
cmpl $0x0, 0xc(%rax)
jne 0x1baef
movq 0x4f504(%rip), %rdi     # 0x6afd8
leaq 0x383bc(%rip), %rsi     # 0x53e97
callq 0x4230
movq %rax, %rdi
movq 0x4f4c6(%rip), %rsi     # 0x6afb0
callq 0x4260
jmp 0x1baf1
movq 0x4f4e0(%rip), %rdi     # 0x6afd8
leaq 0x383a7(%rip), %rsi     # 0x53ea6
callq 0x4230
movq %rax, %rdi
movq 0x28(%rsp), %rax
movsd 0x3d8(%rax), %xmm0
callq 0x4440
movq %rax, %rdi
movq 0x4f48d(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x4f4a9(%rip), %rdi     # 0x6afd8
leaq 0x38382(%rip), %rsi     # 0x53eb8
callq 0x4230
movq %rax, %rdi
movq 0x28(%rsp), %rax
movb 0x3c8(%rax), %al
andb $0x1, %al
movzbl %al, %esi
callq 0x4410
movq %rax, %rdi
movq 0x4f453(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rax
cmpl $0x0, 0xc(%rax)
jne 0x1bba0
movq 0x4f464(%rip), %rdi     # 0x6afd8
leaq 0x3834c(%rip), %rsi     # 0x53ec7
callq 0x4230
movq %rax, %rdi
movq 0x28(%rsp), %rax
movq 0x10(%rax), %rsi
callq 0x4080
movq %rax, %rdi
movq 0x4f415(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rax
cmpl $0x1, 0xc(%rax)
jne 0x1bc11
movq 0x4f426(%rip), %rdi     # 0x6afd8
leaq 0x38325(%rip), %rsi     # 0x53ede
callq 0x4230
movq %rax, %rdi
movq 0x28(%rsp), %rax
movq 0x18(%rax), %rsi
callq 0x4080
movq %rax, %rdi
movq 0x4f3d7(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x4f3f3(%rip), %rdi     # 0x6afd8
leaq 0x3830a(%rip), %rsi     # 0x53ef6
callq 0x4230
movq 0x28(%rsp), %rsi
movq %rax, %rdi
addq $0x20, %rsi
callq 0x3b200
movq %rax, %rdi
movq 0x4f3a4(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x4f3c0(%rip), %rdi     # 0x6afd8
leaq 0x382eb(%rip), %rsi     # 0x53f0a
callq 0x4230
movq %rax, %rdi
movq 0x4f382(%rip), %rsi     # 0x6afb0
callq 0x4260
movq $0x0, 0x68(%rsp)
movq 0x28(%rsp), %rdi
movq 0x68(%rsp), %rax
movq %rax, 0x18(%rsp)
addq $0x60, %rdi
callq 0x1f9c0
movq %rax, %rcx
movq 0x18(%rsp), %rax
cmpq %rcx, %rax
jae 0x1bd38
movq 0x4f36c(%rip), %rdi     # 0x6afd8
leaq 0x382e1(%rip), %rsi     # 0x53f54
callq 0x4230
movq %rax, %rdi
movq 0x68(%rsp), %rsi
callq 0x4080
movq %rax, %rdi
movq 0x4f321(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rdi
addq $0x60, %rdi
movq 0x68(%rsp), %rsi
callq 0x1f9e0
movq %rax, %rsi
movq 0x4f327(%rip), %rdi     # 0x6afd8
callq 0x3d640
movq %rax, %rdi
movq 0x4f2f0(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x4f30c(%rip), %rdi     # 0x6afd8
leaq 0x38299(%rip), %rsi     # 0x53f6c
callq 0x4230
movq %rax, %rdi
movq 0x68(%rsp), %rsi
callq 0x4080
movq %rax, %rdi
movq 0x4f2c1(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rdi
addq $0x78, %rdi
movq 0x68(%rsp), %rsi
callq 0x1f9e0
movq %rax, %rsi
movq 0x4f2c7(%rip), %rdi     # 0x6afd8
callq 0x3d640
movq %rax, %rdi
movq 0x4f290(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x68(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x68(%rsp)
jmp 0x1bc3c
movq 0x4f299(%rip), %rdi     # 0x6afd8
leaq 0x381ce(%rip), %rsi     # 0x53f14
callq 0x4230
movq %rax, %rdi
movq 0x4f25b(%rip), %rsi     # 0x6afb0
callq 0x4260
movq $0x0, 0x60(%rsp)
movq 0x28(%rsp), %rdi
movq 0x60(%rsp), %rax
movq %rax, 0x10(%rsp)
addq $0x108, %rdi            # imm = 0x108
callq 0x1ffd0
movq %rax, %rcx
movq 0x10(%rsp), %rax
cmpq %rcx, %rax
jae 0x1be01
movq 0x4f246(%rip), %rdi     # 0x6afd8
leaq 0x38194(%rip), %rsi     # 0x53f2d
callq 0x4230
movq %rax, %rdi
movq 0x60(%rsp), %rsi
callq 0x4080
movq %rax, %rdi
movq 0x4f1fb(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rdi
addq $0x108, %rdi            # imm = 0x108
movq 0x60(%rsp), %rsi
callq 0x1ff80
movq %rax, %rsi
movq 0x4f1fe(%rip), %rdi     # 0x6afd8
callq 0x3ac20
movq %rax, %rdi
movq 0x4f1c7(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x60(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x60(%rsp)
jmp 0x1bd63
movq 0x4f1d0(%rip), %rdi     # 0x6afd8
leaq 0x3812d(%rip), %rsi     # 0x53f3c
callq 0x4230
movq %rax, %rdi
movq 0x4f192(%rip), %rsi     # 0x6afb0
callq 0x4260
movq $0x0, 0x58(%rsp)
movq 0x28(%rsp), %rdi
movq 0x58(%rsp), %rax
movq %rax, 0x8(%rsp)
addq $0xd8, %rdi
callq 0x1f9c0
movq %rax, %rcx
movq 0x8(%rsp), %rax
cmpq %rcx, %rax
jae 0x1bf31
movq 0x4f179(%rip), %rdi     # 0x6afd8
leaq 0x380e7(%rip), %rsi     # 0x53f4d
callq 0x4230
movq %rax, %rdi
movq 0x58(%rsp), %rsi
callq 0x4080
movq %rax, %rdi
movq 0x4f12e(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rdi
addq $0xd8, %rdi
movq 0x58(%rsp), %rsi
callq 0x1f9e0
movq %rax, %rsi
movq 0x4f131(%rip), %rdi     # 0x6afd8
callq 0x3d640
movq %rax, %rdi
movq 0x4f0fa(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x4f116(%rip), %rdi     # 0x6afd8
leaq 0x3809c(%rip), %rsi     # 0x53f65
callq 0x4230
movq %rax, %rdi
movq 0x58(%rsp), %rsi
callq 0x4080
movq %rax, %rdi
movq 0x4f0cb(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rdi
addq $0xf0, %rdi
movq 0x58(%rsp), %rsi
callq 0x1f9e0
movq %rax, %rsi
movq 0x4f0ce(%rip), %rdi     # 0x6afd8
callq 0x3d640
movq %rax, %rdi
movq 0x4f097(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x58(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x58(%rsp)
jmp 0x1be2c
movq 0x4f0a0(%rip), %rdi     # 0x6afd8
movq 0x4f071(%rip), %rsi     # 0x6afb0
callq 0x4260
movq %rax, %rdi
leaq 0x3802c(%rip), %rsi     # 0x53f7a
callq 0x4230
movq %rax, %rdi
movq 0x4f053(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x4f06f(%rip), %rdi     # 0x6afd8
leaq 0x3802e(%rip), %rsi     # 0x53f9e
callq 0x4230
movq %rax, %rdi
movq 0x4f031(%rip), %rsi     # 0x6afb0
callq 0x4260
movq $0x0, 0x50(%rsp)
movq 0x28(%rsp), %rdi
movq 0x50(%rsp), %rax
movq %rax, (%rsp)
addq $0x40, %rdi
callq 0x1f630
movq %rax, %rcx
movq (%rsp), %rax
cmpq %rcx, %rax
jae 0x1c106
movq 0x28(%rsp), %rdi
addq $0x40, %rdi
movq 0x50(%rsp), %rsi
callq 0x1f650
movq %rax, %rdi
callq 0x1f530
movq %rax, 0x40(%rsp)
movq %rdx, 0x48(%rsp)
movq 0x4eff8(%rip), %rdi     # 0x6afd8
leaq 0x37fd1(%rip), %rsi     # 0x53fb8
callq 0x4230
movq %rax, %rdi
leaq 0x40(%rsp), %rsi
callq 0x3b200
movq %rax, %rdi
movq 0x4efad(%rip), %rsi     # 0x6afb0
callq 0x4260
movq $0x0, 0x38(%rsp)
movq 0x38(%rsp), %rax
cmpq 0x40(%rsp), %rax
jae 0x1c0f1
movq $0x0, 0x30(%rsp)
movq 0x30(%rsp), %rax
cmpq 0x48(%rsp), %rax
jae 0x1c0dc
movq 0x4ef97(%rip), %rdi     # 0x6afd8
leaq 0x37f8a(%rip), %rsi     # 0x53fd2
callq 0x4230
movq %rax, %rdi
movq 0x38(%rsp), %rsi
callq 0x4080
movq %rax, %rdi
leaq 0x39d6e(%rip), %rsi     # 0x55dd2
callq 0x4230
movq %rax, %rdi
movq 0x30(%rsp), %rsi
callq 0x4080
movq %rax, %rdi
leaq 0x38b3d(%rip), %rsi     # 0x54bbd
callq 0x4230
movq %rax, %rdi
movq 0x4ef21(%rip), %rsi     # 0x6afb0
callq 0x4260
movq 0x28(%rsp), %rdi
addq $0x40, %rdi
movq 0x50(%rsp), %rsi
callq 0x1f650
movq %rax, %rdi
movq 0x38(%rsp), %rsi
callq 0x1f5c0
movq %rax, %rdi
movq 0x30(%rsp), %rsi
callq 0x1f5f0
movq (%rax), %rdi
callq 0x4a3d0
movq 0x30(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x30(%rsp)
jmp 0x1c02a
jmp 0x1c0de
movq 0x38(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x38(%rsp)
jmp 0x1c011
jmp 0x1c0f3
movq 0x50(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x50(%rsp)
jmp 0x1bf8d
addq $0x78, %rsp
retq
nopl (%rax,%rax)