// File: /workspace/github_c_makefile_star2_O0/olcaytaner[P]Isell/multivariaterule.c
// Function: find_best_multivariate_condition_lp
Decisionconditionptr find_best_multivariate_condition_lp(Instanceptr* growset, int positive)
{
 /*!Last Changed 17.11.2005 added result->freeparam*/
 /*!Last Changed 26.06.2005*/
 /*!Last Changed 28.05.2004*/
 Mlpparameters mlpparams;
 Mlpnetwork neuralnetwork;
 matrix train;
 Decisionconditionptr result;
 int i;
 result = empty_condition();
 result->conditiontype = MULTIVARIATE_CONDITION;
 result->featureindex = LINEAR;
 result->freeparam = current_dataset->multifeaturecount - 1;
 mlpparams = prepare_Mlpparameters(*growset, *growset, 0, 0.0, 0, NULL, 0, 0.0, 0.0, 0, CLASSIFICATION);
 train = instancelist_to_matrix(*growset, 2, positive, MULTIVARIATE_LINEAR);
 neuralnetwork = mlpn_general(train, train, &mlpparams, CLASSIFICATION);
 result->comparison = '>';
 result->w0 = neuralnetwork.weights->values[1][0] - neuralnetwork.weights->values[0][0];
 result->w = matrix_alloc(1, current_dataset->multifeaturecount - 1);
 for (i = 0; i < current_dataset->multifeaturecount - 1; i++)
   result->w.values[0][i] = neuralnetwork.weights->values[0][i + 1] - neuralnetwork.weights->values[1][i + 1];
 free_mlpnnetwork(&neuralnetwork);
 matrix_free(train);
 return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x2c0, %rsp            # imm = 0x2C0
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movb $0x0, %al
callq 0xadea0
movq %rax, -0x150(%rbp)
movq -0x150(%rbp), %rax
movl $0x1, 0x40(%rax)
movq -0x150(%rbp), %rax
movl $0xfffffffe, (%rax)     # imm = 0xFFFFFFFE
leaq 0x9821e(%rip), %rax     # 0x105840
movq (%rax), %rax
movl 0x1c0(%rax), %ecx
subl $0x1, %ecx
movq -0x150(%rbp), %rax
movl %ecx, 0x3c(%rax)
movq -0x8(%rbp), %rax
movq (%rax), %rsi
movq -0x8(%rbp), %rax
movq (%rax), %rdx
leaq -0x1e8(%rbp), %rdi
xorl %r8d, %r8d
xorps %xmm2, %xmm2
xorl %eax, %eax
movl %eax, %r9d
movl %r8d, %ecx
movaps %xmm2, %xmm0
movl $0x0, (%rsp)
movaps %xmm2, %xmm1
movl $0x0, 0x8(%rsp)
movl $0x0, 0x10(%rsp)
callq 0x61f60
leaq -0xa0(%rbp), %rdi
leaq -0x1e8(%rbp), %rsi
movl $0x90, %edx
callq 0x42b0
movq -0x8(%rbp), %rax
movq (%rax), %rdi
movl -0xc(%rbp), %edx
movl $0x2, %esi
movl $0xfffffffe, %ecx       # imm = 0xFFFFFFFE
callq 0x44720
movq %rax, -0x1f8(%rbp)
movq %rdx, -0x1f0(%rbp)
movq -0x1f8(%rbp), %rax
movq %rax, -0x148(%rbp)
movq -0x1f0(%rbp), %rax
movq %rax, -0x140(%rbp)
movq -0x148(%rbp), %rsi
movq -0x140(%rbp), %rdx
movq -0x148(%rbp), %rcx
movq -0x140(%rbp), %r8
leaq -0x290(%rbp), %rdi
leaq -0xa0(%rbp), %r9
xorl %eax, %eax
movl $0x0, (%rsp)
callq 0x61710
leaq -0x138(%rbp), %rdi
leaq -0x290(%rbp), %rsi
movl $0x98, %edx
callq 0x42b0
movq -0x150(%rbp), %rax
movb $0x3e, 0x4(%rax)
movq -0x138(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rax
movsd (%rax), %xmm0
movq -0x138(%rbp), %rax
movq 0x8(%rax), %rax
movq (%rax), %rax
subsd (%rax), %xmm0
movq -0x150(%rbp), %rax
movsd %xmm0, 0x30(%rax)
movq -0x150(%rbp), %rax
movq %rax, -0x2a8(%rbp)
leaq 0x980c7(%rip), %rax     # 0x105840
movq (%rax), %rax
movl 0x1c0(%rax), %esi
subl $0x1, %esi
movl $0x1, %edi
callq 0x57fc0
movq %rax, %rcx
movq -0x2a8(%rbp), %rax
movq %rcx, -0x2a0(%rbp)
movq %rdx, -0x298(%rbp)
movq -0x2a0(%rbp), %rcx
movq %rcx, 0x20(%rax)
movq -0x298(%rbp), %rcx
movq %rcx, 0x28(%rax)
movl $0x0, -0x154(%rbp)
movl -0x154(%rbp), %eax
leaq 0x9806c(%rip), %rcx     # 0x105840
movq (%rcx), %rcx
movl 0x1c0(%rcx), %ecx
subl $0x1, %ecx
cmpl %ecx, %eax
jge 0x6d851
movq -0x138(%rbp), %rax
movq 0x8(%rax), %rax
movq (%rax), %rax
movl -0x154(%rbp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
movsd (%rax,%rcx,8), %xmm0
movq -0x138(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x8(%rax), %rax
movl -0x154(%rbp), %ecx
addl $0x1, %ecx
movslq %ecx, %rcx
subsd (%rax,%rcx,8), %xmm0
movq -0x150(%rbp), %rax
movq 0x28(%rax), %rax
movq (%rax), %rax
movslq -0x154(%rbp), %rcx
movsd %xmm0, (%rax,%rcx,8)
movl -0x154(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x154(%rbp)
jmp 0x6d7c7
leaq -0x138(%rbp), %rdi
callq 0x63ab0
movq -0x148(%rbp), %rdi
movq -0x140(%rbp), %rsi
callq 0x59ea0
movq -0x150(%rbp), %rax
addq $0x2c0, %rsp            # imm = 0x2C0
popq %rbp
retq