// File: btbujiangjun[P]abcdl/example/sessionq.cpp
// Function: main
int main(int argc, char** argv){
    abcdl::utils::log::set_min_log_level(abcdl::utils::log::INFO);
    abcdl::utils::log::initialize_log(argc, argv);

    abcdl::utils::LibsvmHelper<real> helper;
    abcdl::algebra::Mat train_data;
    abcdl::algebra::Mat train_label;
    abcdl::algebra::Mat test_data;
    abcdl::algebra::Mat test_label;
    size_t feature_dim = 251;
    size_t label_dim = 2;
    
    std::vector<std::string> paths;
    paths.push_back("./data/sessionq/sessionq.train.libsvmaa");
    paths.push_back("./data/sessionq/sessionq.train.libsvmab");
    paths.push_back("./data/sessionq/sessionq.train.libsvmac");
    paths.push_back("./data/sessionq/sessionq.train.libsvmad");
    paths.push_back("./data/sessionq/sessionq.train.libsvmae");
    paths.push_back("./data/sessionq/sessionq.train.libsvmaf");
    paths.push_back("./data/sessionq/sessionq.train.libsvmag");
    paths.push_back("./data/sessionq/sessionq.train.libsvmah");
    paths.push_back("./data/sessionq/sessionq.train.libsvmai");
    
    SessionQ sessionq;
    sessionq.init(feature_dim, label_dim);
    
    helper.read_data(feature_dim, label_dim, "./data/sessionq/sessionq.train.libsvmaj", &test_data, &test_label);
    for(auto& path : paths){
        helper.read_data(feature_dim, label_dim, path, &train_data, &train_label);
        sessionq.pass(train_data, train_label, test_data, test_label);
    }
}

// Assembly:
subq $0x418, %rsp            # imm = 0x418
movl $0x0, 0x414(%rsp)
movl %edi, 0x410(%rsp)
movq %rsi, 0x408(%rsp)
xorl %edi, %edi
callq 0xb8ce0
movl 0x410(%rsp), %edi
movq 0x408(%rsp), %rsi
callq 0xb87d0
leaq 0x3f8(%rsp), %rdi
callq 0x19d10
leaq 0x3d0(%rsp), %rdi
callq 0x633f0
leaq 0x3a8(%rsp), %rdi
callq 0x633f0
jmp 0xd945
leaq 0x370(%rsp), %rdi
callq 0x633f0
jmp 0xd954
leaq 0x348(%rsp), %rdi
callq 0x633f0
jmp 0xd963
movq $0xfb, 0x340(%rsp)
movq $0x2, 0x338(%rsp)
leaq 0x320(%rsp), %rdi
callq 0x19d30
leaq 0x2ff(%rsp), %rdi
movq %rdi, 0x58(%rsp)
callq 0xc990
movq 0x58(%rsp), %rdx
leaq 0xaf86e(%rip), %rsi     # 0xbd214
leaq 0x300(%rsp), %rdi
callq 0xc770
jmp 0xd9b5
leaq 0x320(%rsp), %rdi
leaq 0x300(%rsp), %rsi
callq 0x19d40
jmp 0xd9cc
leaq 0x300(%rsp), %rdi
callq 0xc340
leaq 0x2ff(%rsp), %rdi
callq 0xc600
leaq 0x2d7(%rsp), %rdi
movq %rdi, 0x50(%rsp)
callq 0xc990
movq 0x50(%rsp), %rdx
leaq 0xaf838(%rip), %rsi     # 0xbd23c
leaq 0x2d8(%rsp), %rdi
callq 0xc770
jmp 0xda13
leaq 0x320(%rsp), %rdi
leaq 0x2d8(%rsp), %rsi
callq 0x19d40
jmp 0xda2a
leaq 0x2d8(%rsp), %rdi
callq 0xc340
leaq 0x2d7(%rsp), %rdi
callq 0xc600
leaq 0x2af(%rsp), %rdi
movq %rdi, 0x48(%rsp)
callq 0xc990
movq 0x48(%rsp), %rdx
leaq 0xaf802(%rip), %rsi     # 0xbd264
leaq 0x2b0(%rsp), %rdi
callq 0xc770
jmp 0xda71
leaq 0x320(%rsp), %rdi
leaq 0x2b0(%rsp), %rsi
callq 0x19d40
jmp 0xda88
leaq 0x2b0(%rsp), %rdi
callq 0xc340
leaq 0x2af(%rsp), %rdi
callq 0xc600
leaq 0x287(%rsp), %rdi
movq %rdi, 0x40(%rsp)
callq 0xc990
movq 0x40(%rsp), %rdx
leaq 0xaf7cc(%rip), %rsi     # 0xbd28c
leaq 0x288(%rsp), %rdi
callq 0xc770
jmp 0xdacf
leaq 0x320(%rsp), %rdi
leaq 0x288(%rsp), %rsi
callq 0x19d40
jmp 0xdae6
leaq 0x288(%rsp), %rdi
callq 0xc340
leaq 0x287(%rsp), %rdi
callq 0xc600
leaq 0x25f(%rsp), %rdi
movq %rdi, 0x38(%rsp)
callq 0xc990
movq 0x38(%rsp), %rdx
leaq 0xaf796(%rip), %rsi     # 0xbd2b4
leaq 0x260(%rsp), %rdi
callq 0xc770
jmp 0xdb2d
leaq 0x320(%rsp), %rdi
leaq 0x260(%rsp), %rsi
callq 0x19d40
jmp 0xdb44
leaq 0x260(%rsp), %rdi
callq 0xc340
leaq 0x25f(%rsp), %rdi
callq 0xc600
leaq 0x237(%rsp), %rdi
movq %rdi, 0x30(%rsp)
callq 0xc990
movq 0x30(%rsp), %rdx
leaq 0xaf760(%rip), %rsi     # 0xbd2dc
leaq 0x238(%rsp), %rdi
callq 0xc770
jmp 0xdb8b
leaq 0x320(%rsp), %rdi
leaq 0x238(%rsp), %rsi
callq 0x19d40
jmp 0xdba2
leaq 0x238(%rsp), %rdi
callq 0xc340
leaq 0x237(%rsp), %rdi
callq 0xc600
leaq 0x20f(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0xc990
movq 0x28(%rsp), %rdx
leaq 0xaf72a(%rip), %rsi     # 0xbd304
leaq 0x210(%rsp), %rdi
callq 0xc770
jmp 0xdbe9
leaq 0x320(%rsp), %rdi
leaq 0x210(%rsp), %rsi
callq 0x19d40
jmp 0xdc00
leaq 0x210(%rsp), %rdi
callq 0xc340
leaq 0x20f(%rsp), %rdi
callq 0xc600
leaq 0x1e7(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0xc990
movq 0x20(%rsp), %rdx
leaq 0xaf6f4(%rip), %rsi     # 0xbd32c
leaq 0x1e8(%rsp), %rdi
callq 0xc770
jmp 0xdc47
leaq 0x320(%rsp), %rdi
leaq 0x1e8(%rsp), %rsi
callq 0x19d40
jmp 0xdc5e
leaq 0x1e8(%rsp), %rdi
callq 0xc340
leaq 0x1e7(%rsp), %rdi
callq 0xc600
leaq 0x1bf(%rsp), %rdi
movq %rdi, 0x18(%rsp)
callq 0xc990
movq 0x18(%rsp), %rdx
leaq 0xaf6be(%rip), %rsi     # 0xbd354
leaq 0x1c0(%rsp), %rdi
callq 0xc770
jmp 0xdca5
leaq 0x320(%rsp), %rdi
leaq 0x1c0(%rsp), %rsi
callq 0x19d40
jmp 0xdcbc
leaq 0x1c0(%rsp), %rdi
callq 0xc340
leaq 0x1bf(%rsp), %rdi
callq 0xc600
leaq 0x148(%rsp), %rdi
callq 0x19d70
jmp 0xdce5
movq 0x340(%rsp), %rsi
movq 0x338(%rsp), %rdx
leaq 0x148(%rsp), %rdi
callq 0x19d80
jmp 0xdd04
movq 0x340(%rsp), %rax
movq %rax, (%rsp)
movq 0x338(%rsp), %rax
movq %rax, 0x8(%rsp)
leaq 0x127(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0xc990
movq 0x10(%rsp), %rdx
leaq 0xaf641(%rip), %rsi     # 0xbd37c
leaq 0x128(%rsp), %rdi
callq 0xc770
jmp 0xdd4a
movq 0x8(%rsp), %rdx
movq (%rsp), %rsi
leaq 0x3f8(%rsp), %rdi
leaq 0x128(%rsp), %rcx
leaq 0x370(%rsp), %r8
leaq 0x348(%rsp), %r9
callq 0x1a240
jmp 0xdd7a
leaq 0x128(%rsp), %rdi
callq 0xc340
leaq 0x127(%rsp), %rdi
callq 0xc600
leaq 0x320(%rsp), %rax
movq %rax, 0x118(%rsp)
movq 0x118(%rsp), %rdi
callq 0x1a810
movq %rax, 0x110(%rsp)
movq 0x118(%rsp), %rdi
callq 0x1a840
movq %rax, 0x108(%rsp)
leaq 0x110(%rsp), %rdi
leaq 0x108(%rsp), %rsi
callq 0x1a870
testb $0x1, %al
jne 0xddec
jmp 0xe2e0
leaq 0x110(%rsp), %rdi
callq 0x1a8b0
movq %rax, 0x100(%rsp)
movq 0x340(%rsp), %rsi
movq 0x338(%rsp), %rdx
movq 0x100(%rsp), %rcx
leaq 0x3f8(%rsp), %rdi
leaq 0x3d0(%rsp), %r8
leaq 0x3a8(%rsp), %r9
callq 0x1a240
jmp 0xde38
leaq 0xd8(%rsp), %rdi
leaq 0x3d0(%rsp), %rsi
callq 0x1a930
jmp 0xde4f
leaq 0xb0(%rsp), %rdi
leaq 0x3a8(%rsp), %rsi
callq 0x1a930
jmp 0xde66
leaq 0x88(%rsp), %rdi
leaq 0x370(%rsp), %rsi
callq 0x1a930
jmp 0xde7d
leaq 0x60(%rsp), %rdi
leaq 0x348(%rsp), %rsi
callq 0x1a930
jmp 0xde91
leaq 0x148(%rsp), %rdi
leaq 0xd8(%rsp), %rsi
leaq 0xb0(%rsp), %rdx
leaq 0x88(%rsp), %rcx
leaq 0x60(%rsp), %r8
callq 0x1a8c0
jmp 0xdebd
leaq 0x60(%rsp), %rdi
callq 0x63830
leaq 0x88(%rsp), %rdi
callq 0x63830
leaq 0xb0(%rsp), %rdi
callq 0x63830
leaq 0xd8(%rsp), %rdi
callq 0x63830
leaq 0x110(%rsp), %rdi
callq 0x1a9f0
jmp 0xddce
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe37e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe371
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe364
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xdf82
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x300(%rsp), %rdi
callq 0xc340
leaq 0x2ff(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xdfcb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x2d8(%rsp), %rdi
callq 0xc340
leaq 0x2d7(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe014
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x2b0(%rsp), %rdi
callq 0xc340
leaq 0x2af(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe05d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x288(%rsp), %rdi
callq 0xc340
leaq 0x287(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe0a6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x260(%rsp), %rdi
callq 0xc340
leaq 0x25f(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe0ef
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x238(%rsp), %rdi
callq 0xc340
leaq 0x237(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe138
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x210(%rsp), %rdi
callq 0xc340
leaq 0x20f(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe181
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x1e8(%rsp), %rdi
callq 0xc340
leaq 0x1e7(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe1ca
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x1c0(%rsp), %rdi
callq 0xc340
leaq 0x1bf(%rsp), %rdi
callq 0xc600
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe34a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe33d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe245
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x128(%rsp), %rdi
callq 0xc340
leaq 0x127(%rsp), %rdi
callq 0xc600
jmp 0xe33d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe2d1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe2c4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
jmp 0xe2b7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x3a0(%rsp)
movl %eax, 0x39c(%rsp)
leaq 0x60(%rsp), %rdi
callq 0x63830
leaq 0x88(%rsp), %rdi
callq 0x63830
leaq 0xb0(%rsp), %rdi
callq 0x63830
leaq 0xd8(%rsp), %rdi
callq 0x63830
jmp 0xe33d
leaq 0x148(%rsp), %rdi
callq 0x1aa10
leaq 0x320(%rsp), %rdi
callq 0x1aa20
leaq 0x348(%rsp), %rdi
callq 0x63830
leaq 0x370(%rsp), %rdi
callq 0x63830
leaq 0x3a8(%rsp), %rdi
callq 0x63830
leaq 0x3d0(%rsp), %rdi
callq 0x63830
movl 0x414(%rsp), %eax
addq $0x418, %rsp            # imm = 0x418
retq
leaq 0x148(%rsp), %rdi
callq 0x1aa10
leaq 0x320(%rsp), %rdi
callq 0x1aa20
leaq 0x348(%rsp), %rdi
callq 0x63830
leaq 0x370(%rsp), %rdi
callq 0x63830
leaq 0x3a8(%rsp), %rdi
callq 0x63830
leaq 0x3d0(%rsp), %rdi
callq 0x63830
movq 0x3a0(%rsp), %rdi
callq 0xc980
nopl (%rax,%rax)