// File: /workspace/github_cpp_makefile_star2_O3/0asa[P]TTree-source/Scorer.cpp
// Function: Scorer::getGroupScore(Learner*, std::vector<unsigned int, std::allocator<unsigned int>>&, std::vector<unsigned int, std::allocator<unsigned int>>&, ScoreInfo&, int)
void Scorer::getGroupScore(Learner* weak,std::vector<unsigned int> &ind, std::vector<unsigned int> &cand, ScoreInfo &si, int treeType) {
	Score score;
	weak->setLS(&ind);
	if (treeType == RANDOMTTSTUMP || treeType == EXTRATTSTUMP)
		((GStump*)weak)->setAttCand(&cand);
	else 
		weak->setAttCand(&cand);
	weak->learn();

	Result result = weak->test(&ind);
	result.shrink();
	
	ContingencyTable ctable = result.getContingencyTable();	
	std::vector<double> th = result.getPossibleProbTh();

	if (treeType == EXTRATREE || treeType == EXTRATTSTUMP)
		th = Sampler::random(th, 1);
	
	for (int t = 0 ; t < th.size() ; ++t) {
		ctable = result.getContingencyTable(th[t]);
		ctable.compact(th[t]);
		si.update(weak,th[t],score.getScore(ctable));
	}
	
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x178, %rsp            # imm = 0x178
movl %r9d, %ebx
movq %r8, 0x20(%rsp)
movq %rcx, %r12
movq %rdx, %r15
movq %rsi, %r14
movl $0x1, 0x1c(%rsp)
movq %rsi, %rdi
movq %rdx, %rsi
callq 0x1057c
leal -0x5(%rbx), %eax
movq %r14, %rdi
movq %r12, %rsi
cmpl $0x1, %eax
ja 0x13810
callq 0xeb34
jmp 0x13815
callq 0x10588
movq (%r14), %rax
movq %r14, %rdi
callq *(%rax)
movq (%r14), %rax
leaq 0xa8(%rsp), %rdi
movq %r14, %rsi
movq %r15, %rdx
callq *0x20(%rax)
leaq 0xb0(%rsp), %rdi
callq 0x1482e
leaq 0x100(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
movsd 0x27ba(%rip), %xmm0     # 0x16010
callq 0x12a64
movq %rsp, %rdi
leaq 0xa8(%rsp), %rsi
callq 0x1290c
cmpl $0x6, %ebx
je 0x13875
cmpl $0x3, %ebx
jne 0x138d8
leaq 0x30(%rsp), %rdi
movq %rsp, %rsi
movl $0x1, %edx
callq 0x14732
movq (%rsp), %rdi
movq 0x10(%rsp), %rsi
movaps 0x30(%rsp), %xmm0
movaps %xmm0, (%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0x10(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x30(%rsp)
movq $0x0, 0x40(%rsp)
testq %rdi, %rdi
je 0x138d8
subq %rdi, %rsi
callq 0x3210
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0x138d8
movq 0x40(%rsp), %rsi
subq %rdi, %rsi
callq 0x3210
movq (%rsp), %rdi
cmpq %rdi, 0x8(%rsp)
je 0x139db
leaq 0x108(%rsp), %r15
leaq 0x38(%rsp), %r12
xorl %ebp, %ebp
leaq 0x30(%rsp), %r13
leaq 0x100(%rsp), %rbx
movsd (%rdi,%rbp,8), %xmm0
movq %r13, %rdi
leaq 0xa8(%rsp), %rsi
callq 0x12a64
movq 0x30(%rsp), %rax
movq %rax, 0x100(%rsp)
movq %r15, %rdi
movq %r12, %rsi
callq 0x14aa6
leaq 0x120(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x75b6
leaq 0x138(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0x75b6
leaq 0x150(%rsp), %rdi
leaq 0x80(%rsp), %rsi
callq 0x75b6
movups 0x60(%r12), %xmm0
movups %xmm0, 0x60(%r15)
movq %r13, %rdi
callq 0xc430
movq (%rsp), %rax
movsd (%rax,%rbp,8), %xmm0
movq %rbx, %rdi
callq 0xc596
movq (%rsp), %rax
movsd (%rax,%rbp,8), %xmm0
movsd %xmm0, 0x28(%rsp)
leaq 0x1c(%rsp), %rdi
movq %rbx, %rsi
callq 0x1300c
movaps %xmm0, %xmm1
movq 0x20(%rsp), %rdi
movq %r14, %rsi
movsd 0x28(%rsp), %xmm0
callq 0x13536
incq %rbp
movq (%rsp), %rdi
movq 0x8(%rsp), %rax
subq %rdi, %rax
sarq $0x3, %rax
cmpq %rbp, %rax
ja 0x13903
testq %rdi, %rdi
je 0x139ed
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x3210
leaq 0x100(%rsp), %rdi
callq 0xc430
leaq 0xa8(%rsp), %rdi
callq 0x12826
addq $0x178, %rsp            # imm = 0x178
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x13a29
movq %rax, %rbx
jmp 0x13a51
jmp 0x13a22
movq %rax, %rbx
jmp 0x13a5e
jmp 0x13a29
movq %rax, %rbx
jmp 0x13a3b
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0xc430
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x13a51
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x3210
leaq 0x100(%rsp), %rdi
callq 0xc430
leaq 0xa8(%rsp), %rdi
callq 0x12826
movq %rbx, %rdi
callq 0x3320
nop