// File: /workspace/github_c_makefile_star2_O1/olcaytaner[P]Isell/process.c
// Function: export_datafolds
void export_datafolds(char* separator, int newseed)
{
 /*!Last Changed 21.04.2007 added export_single_file*/
 /*!Last Changed 30.10.2005*/
 /*!Last Changed 16.10.2005*/
 /*!Last Changed 26.04.2005 added runcount and mysrand*/
 /*!Last Changed 02.02.2004 added safemalloc*/
 int i, k, **partition, *classes, *classcounts;
 mustnormalize = NO;
 get_prior_information();
 mysrand(newseed);
 classes = read_train_and_test_lines(&classcounts);
 partition = safemalloc(get_parameter_i("runcount") * sizeof(int *), "export_datafolds", 10);
 for (k = 0; k < get_parameter_i("runcount"); k++)
   partition[k] = stratified_partition(classes, trainlinecount, current_dataset->classno, classcounts);
 for (k = 0; k < get_parameter_i("runcount"); k++)
   for (i = 0; i < get_parameter_i("foldcount"); i++)
    {
     get_fold(i, partition[k]);
     pre_process();
     if (get_parameter_l("namestype") != NAMES_CMU)
      {
       export_single_file(separator, 0, k, i, traindata, NULL);
       export_single_file(separator, 1, k, i, testdata, NULL);
      }
     else
       export_single_file(separator, 0, k, i, traindata, testdata);
     post_process(YES);
     if (traindata)
      {
       deallocate(traindata);
       traindata = NULL;
      }
     if (testdata)
      {
       deallocate(testdata);
       testdata = NULL;
      }
    }
 free_2d((void**)partition, get_parameter_i("runcount"));
 free_train_and_test_lines();
 safe_free(classes);
 if (current_dataset->classno > 0)
   safe_free(classcounts);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %esi, %ebx
movq %rdi, %r14
movl $0x0, 0x2d713b(%rip)    # 0x334e70
callq 0x5cde7
movl %ebx, %edi
callq 0x39f5b
leaq 0x8(%rsp), %rdi
callq 0x5d87f
movq %rax, %rbp
leaq 0x49ef8(%rip), %rbx     # 0xa7c4d
movq %rbx, %rdi
callq 0x5341c
movslq %eax, %rdi
shlq $0x3, %rdi
leaq 0x4abe4(%rip), %rsi     # 0xa894f
movl $0xa, %edx
callq 0x390f5
movq %rax, %r15
movq %rbx, %rdi
callq 0x5341c
testl %eax, %eax
jle 0x5ddc4
movq 0x8(%rsp), %rbx
xorl %r13d, %r13d
leaq 0x49eba(%rip), %r12     # 0xa7c4d
movl 0x74777(%rip), %esi     # 0xd2510
movq 0x74ad0(%rip), %rax     # 0xd2870
movl 0x10(%rax), %edx
movq %rbp, %rdi
movq %rbx, %rcx
callq 0x2f14d
movq %rax, (%r15,%r13,8)
incq %r13
movq %r12, %rdi
callq 0x5341c
cltq
cmpq %rax, %r13
jl 0x5dd93
movq %rbp, 0x10(%rsp)
leaq 0x49e7d(%rip), %rdi     # 0xa7c4d
callq 0x5341c
testl %eax, %eax
jle 0x5ded3
xorl %r12d, %r12d
leaq 0x4dd35(%rip), %r13     # 0xabb1c
leaq 0x4628b(%rip), %rbp     # 0xa4079
movq %r13, %rdi
callq 0x5341c
testl %eax, %eax
jle 0x5deb9
xorl %ebx, %ebx
movq (%r15,%r12,8), %rsi
movl %ebx, %edi
callq 0x5d07d
callq 0x5e071
movq %rbp, %rdi
callq 0x535f7
movq 0x2d7011(%rip), %r8     # 0x334e30
cmpl $0x5, %eax
jne 0x5de37
movq 0x2d700d(%rip), %r9     # 0x334e38
movq %r14, %rdi
xorl %esi, %esi
movl %r12d, %edx
movl %ebx, %ecx
jmp 0x5de60
movq %r14, %rdi
xorl %esi, %esi
movl %r12d, %edx
movl %ebx, %ecx
xorl %r9d, %r9d
callq 0x5dc27
movq 0x2d6fe8(%rip), %r8     # 0x334e38
movq %r14, %rdi
movl $0x1, %esi
movl %r12d, %edx
movl %ebx, %ecx
xorl %r9d, %r9d
callq 0x5dc27
movl $0x1, %edi
callq 0x5c49b
movq 0x2d6fba(%rip), %rdi    # 0x334e30
testq %rdi, %rdi
je 0x5de8b
callq 0x2f616
movq $0x0, 0x2d6fa5(%rip) # 0x334e30
movq 0x2d6fa6(%rip), %rdi    # 0x334e38
testq %rdi, %rdi
je 0x5dea7
callq 0x2f616
movq $0x0, 0x2d6f91(%rip) # 0x334e38
incl %ebx
movq %r13, %rdi
callq 0x5341c
cmpl %eax, %ebx
jl 0x5de00
incq %r12
leaq 0x49d8a(%rip), %rdi     # 0xa7c4d
callq 0x5341c
cltq
cmpq %rax, %r12
jl 0x5ddee
leaq 0x49d73(%rip), %rdi     # 0xa7c4d
callq 0x5341c
movq %r15, %rdi
movl %eax, %esi
callq 0x3915f
callq 0x60317
movq 0x10(%rsp), %rdi
callq 0x39194
movq 0x74971(%rip), %rax     # 0xd2870
cmpl $0x0, 0x10(%rax)
jle 0x5df1d
movq 0x8(%rsp), %rdi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x39194
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq