// File: /workspace/github_c_makefile_star2_O3/SimpleDoger[P]Darknet_CPU_Only/image.c
// Function: test_resize
void test_resize(char *filename)
{
    image im = load_image(filename, 0,0, 3);
    float mag = mag_array(im.data, im.w*im.h*im.c);
    printf("L2 Norm: %f\n", mag);
    image gray = grayscale_image(im);

    image c1 = copy_image(im);
    image c2 = copy_image(im);
    image c3 = copy_image(im);
    image c4 = copy_image(im);
    distort_image(c1, .1, 1.5, 1.5);
    distort_image(c2, -.1, .66666, .66666);
    distort_image(c3, .1, 1.5, .66666);
    distort_image(c4, .1, .66666, 1.5);


    show_image(im,   "Original", 1);
    show_image(gray, "Gray", 1);
    show_image(c1, "C1", 1);
    show_image(c2, "C2", 1);
    show_image(c3, "C3", 1);
    show_image(c4, "C4", 1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movq %rdi, %rsi
leaq 0xc0(%rsp), %r14
pushq $0x3
popq %rbx
movq %r14, %rdi
movl %ebx, %edx
callq 0x1b21a
movq 0x10(%r14), %r12
movq (%r14), %r15
movq %r15, %xmm0
movdqa %xmm0, 0x20(%rsp)
pshufd $0x55, %xmm0, %xmm0     # xmm0 = xmm0[1,1,1,1]
movd %xmm0, %eax
movl 0x8(%r14), %ebp
imull %ebp, %r15d
imull %eax, %r15d
movq %r12, %rdi
movl %r15d, %esi
callq 0xf92d
cvtss2sd %xmm0, %xmm0
leaq 0x53736(%rip), %rdi     # 0x57962
movb $0x1, %al
callq 0x3160
movq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
movups (%r14), %xmm0
movups %xmm0, (%rsp)
leaq 0xa8(%rsp), %rdi
callq 0x1a847
movd %ebp, %xmm0
movd 0xc(%r14), %xmm1
punpcklqdq %xmm0, %xmm1    # xmm1 = xmm1[0],xmm0[0]
movaps 0x20(%rsp), %xmm0
shufps $0x24, %xmm1, %xmm0     # xmm0 = xmm0[0,1],xmm1[2,0]
movaps %xmm0, 0x20(%rsp)
movaps %xmm0, 0x90(%rsp)
movslq %r15d, %r13
pushq $0x4
popq %r15
movq %r13, %rdi
movq %r15, %rsi
callq 0x3250
movq %rax, 0xa0(%rsp)
leaq (,%r13,4), %rbp
movq %rax, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x32b0
movaps 0x20(%rsp), %xmm0
movaps %xmm0, 0x70(%rsp)
movq %r13, %rdi
movq %r15, %rsi
callq 0x3250
movq %rax, 0x80(%rsp)
movq %rax, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x32b0
movaps 0x20(%rsp), %xmm0
movaps %xmm0, 0x50(%rsp)
movq %r13, %rdi
movq %r15, %rsi
callq 0x3250
movq %rax, 0x60(%rsp)
movq %rax, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x32b0
movaps 0x20(%rsp), %xmm0
movaps %xmm0, 0x30(%rsp)
movq %r13, %rdi
movq %r15, %rsi
callq 0x3250
movq %rax, 0x40(%rsp)
movq %rax, %rdi
movq %r12, %rsi
movq %rbp, %rdx
callq 0x32b0
movq 0xa0(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x90(%rsp), %xmm0
movups %xmm0, (%rsp)
movss 0x50f57(%rip), %xmm0    # 0x55298
movss 0x50f53(%rip), %xmm1    # 0x5529c
movaps %xmm1, %xmm2
callq 0x1afae
movq 0x80(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x70(%rsp), %xmm0
movups %xmm0, (%rsp)
movss 0x50f31(%rip), %xmm0    # 0x552a0
movss 0x50f2d(%rip), %xmm1    # 0x552a4
movaps %xmm1, %xmm2
callq 0x1afae
movq 0x60(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x50(%rsp), %xmm0
movups %xmm0, (%rsp)
movss 0x50efe(%rip), %xmm0    # 0x55298
movss 0x50efa(%rip), %xmm1    # 0x5529c
movss 0x50efa(%rip), %xmm2    # 0x552a4
callq 0x1afae
movq 0x40(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x30(%rsp), %xmm0
movups %xmm0, (%rsp)
movss 0x50ece(%rip), %xmm0    # 0x55298
movss 0x50ed2(%rip), %xmm1    # 0x552a4
movss 0x50ec2(%rip), %xmm2    # 0x5529c
callq 0x1afae
movq 0x67c12(%rip), %r13     # 0x6bff8
movq (%r13), %rdi
leaq 0x533f0(%rip), %r12     # 0x577e1
leaq 0x53577(%rip), %r15     # 0x5796f
movq %r12, %rsi
movq %r15, %rdx
xorl %eax, %eax
callq 0x3270
movq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
movups (%r14), %xmm0
movups %xmm0, (%rsp)
pushq $0x50
popq %rbp
movq %r15, %rdi
movl %ebx, %esi
movl %ebp, %edx
callq 0x18310
movq (%r13), %rdi
leaq 0x53548(%rip), %r14     # 0x57978
movq %r12, %rsi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3270
leaq 0xa8(%rsp), %rcx
movq 0x10(%rcx), %rax
movq %rax, 0x10(%rsp)
movups (%rcx), %xmm0
movups %xmm0, (%rsp)
movq %r14, %rdi
movl %ebx, %esi
movl %ebp, %edx
callq 0x18310
movq (%r13), %rdi
leaq 0x53511(%rip), %r14     # 0x5797d
movq %r12, %rsi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3270
movq 0xa0(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x90(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r14, %rdi
movl %ebx, %esi
movl %ebp, %edx
callq 0x18310
movq (%r13), %rdi
leaq 0x534d7(%rip), %r14     # 0x57980
movq %r12, %rsi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3270
movq 0x80(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x70(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r14, %rdi
movl %ebx, %esi
movl %ebp, %edx
callq 0x18310
movq (%r13), %rdi
leaq 0x534a0(%rip), %r14     # 0x57983
movq %r12, %rsi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3270
movq 0x60(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x50(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r14, %rdi
movl %ebx, %esi
movl %ebp, %edx
callq 0x18310
movq (%r13), %rdi
leaq 0x5346c(%rip), %r14     # 0x57986
movq %r12, %rsi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3270
movq 0x40(%rsp), %rax
movq %rax, 0x10(%rsp)
movaps 0x30(%rsp), %xmm0
movups %xmm0, (%rsp)
movq %r14, %rdi
movl %ebx, %esi
movl %ebp, %edx
callq 0x18310
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq