Code Monkey home page Code Monkey logo

Comments (7)

kirinnee avatar kirinnee commented on May 9, 2024 2

Impression was from when I ran everything within docker containers: (I hate to post logs but..)

PS D:\same> docker run -v ${PWD}:/anime 4kanime ruby 4k.rb Aug 15, 2019 11:44:14 AM com.aparapi.internal.opencl.OpenCLLoader <clinit> SEVERE: Check your environment. Failed to load codegen native library or possibly failed to locate opencl native library (opencl.dll/opencl.so). Ensure that OpenCL is in your PATH (windows) or in LD_LIBRARY_PATH (linux). Exception in thread "main" javax.imageio.IIOException: Can't read input file! at java.desktop/javax.imageio.ImageIO.read(ImageIO.java:1308) at com.bloc97.anime4k.Main.main(Main.java:36)

Host OS: Windows 10 Pro
Docker-image: openjdk:12-alpine

Perhaps its an alpine problem, I apologize for not checking if its an alpine problem before reporting, but I shall go do that tomorrow.

For starters, I prefer to not have Java installed on my computer.
Bu main reason being it makes if I were running servers that use the image to post-process image or anything of that sort, deployments will be much simpler than to write scripts to pre-install FFMPEG and JDK & curling the jar binary for every server spun up. Building it into a static image would make my other service dependent on it more readily.

from anime4k.

ddouglas87 avatar ddouglas87 commented on May 9, 2024 2

It works without OpenCL but complains while running.

On Docker Ubuntu apt-get install -y ocl-icd-opencl-dev removes the complaining, but I don't notice a speed difference.

from anime4k.

stefnotch avatar stefnotch commented on May 9, 2024 1

Oh, you're right about the OpenCL usage. Anime4k apparently uses Arapi which in turn uses OpenCL to execute Java code on the GPU. This means that you need a Docker image with OpenCL support.

from anime4k.

kirinnee avatar kirinnee commented on May 9, 2024 1

I have created a PR for basic Dockerfile, to build an ubuntu image that's portable.

I also have another one that packs FFMPEG into the image and added a script upscales videos by splitting and merging them (quite slow due to the restart of image kernel each time), should I add a PR for that too?

from anime4k.

stefnotch avatar stefnotch commented on May 9, 2024

Where did you get the impression that it requires OpenCL?

from anime4k.

stefnotch avatar stefnotch commented on May 9, 2024

Regarding Docker container, yes, it could theoretically run inside a Docker container, however, seeing as how it's a realtime algorithm that can easily run on any platform, most likely even the web, I'm not quite seeing the point of using Docker? Is there some use-case that I'm overlooking.

from anime4k.

bloc97 avatar bloc97 commented on May 9, 2024

The algorithm is so simple that it is easy to be bounded by the memory speed. (Copying the image back and forth from the System Memory to the GPU Buffers) If your CPU is powerful enough (Recent CPUs with 8+ cores) it might even outperform GPUs since PCIe lanes are not as fast as the memory bus.

from anime4k.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.