// File: /workspace/github_cpp_makefile_star2_O1/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 0x105a8
leal -0x5(%rbx), %eax
movq %r14, %rdi
movq %r12, %rsi
cmpl $0x1, %eax
ja 0x13894
callq 0xeb3a
jmp 0x13899
callq 0x105b4
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 0x148a4
leaq 0x100(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
movsd 0x2736(%rip), %xmm0     # 0x16010
callq 0x12abe
movq %rsp, %rdi
leaq 0xa8(%rsp), %rsi
callq 0x12974
cmpl $0x6, %ebx
je 0x138f9
cmpl $0x3, %ebx
jne 0x1395c
leaq 0x30(%rsp), %rdi
movq %rsp, %rsi
movl $0x1, %edx
callq 0x147a2
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 0x13945
subq %rdi, %rsi
callq 0x3210
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0x1395c
movq 0x40(%rsp), %rsi
subq %rdi, %rsi
callq 0x3210
movq (%rsp), %rdi
cmpq %rdi, 0x8(%rsp)
je 0x13a5f
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 0x12abe
movq 0x30(%rsp), %rax
movq %rax, 0x100(%rsp)
movq %r15, %rdi
movq %r12, %rsi
callq 0x14b36
leaq 0x120(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0x7550
leaq 0x138(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0x7550
leaq 0x150(%rsp), %rdi
leaq 0x80(%rsp), %rsi
callq 0x7550
movups 0x60(%r12), %xmm0
movups %xmm0, 0x60(%r15)
movq %r13, %rdi
callq 0xc428
movq (%rsp), %rax
movsd (%rax,%rbp,8), %xmm0
movq %rbx, %rdi
callq 0xc58e
movq (%rsp), %rax
movsd (%rax,%rbp,8), %xmm0
movsd %xmm0, 0x28(%rsp)
leaq 0x1c(%rsp), %rdi
movq %rbx, %rsi
callq 0x13090
movaps %xmm0, %xmm1
movq 0x20(%rsp), %rdi
movq %r14, %rsi
movsd 0x28(%rsp), %xmm0
callq 0x135b2
incq %rbp
movq (%rsp), %rdi
movq 0x8(%rsp), %rax
subq %rdi, %rax
sarq $0x3, %rax
cmpq %rbp, %rax
ja 0x13987
testq %rdi, %rdi
je 0x13a71
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x3210
leaq 0x100(%rsp), %rdi
callq 0xc428
leaq 0xa8(%rsp), %rdi
callq 0x1288e
addq $0x178, %rsp            # imm = 0x178
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x13aad
movq %rax, %rbx
jmp 0x13ad5
jmp 0x13aa6
movq %rax, %rbx
jmp 0x13ae2
jmp 0x13aad
movq %rax, %rbx
jmp 0x13abf
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0xc428
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x13ad5
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x3210
leaq 0x100(%rsp), %rdi
callq 0xc428
leaq 0xa8(%rsp), %rdi
callq 0x1288e
movq %rbx, %rdi
callq 0x3320
nop