• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Register
  • Login
ModalAI Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
    • Register
    • Login

    Question for GPU Usage

    FAQs
    3
    5
    520
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • G
      Gyeongmin Kim
      last edited by 26 Jan 2023, 02:25

      Hello, I am trying to use the GPU(Adreno 650) in VOXL2.
      In the voxl-docker-opencv-opencl gitlab, It says this is the expected ouput.

      root@0a4f66eee0a6:/opt/workspace/examples/fast_corners# ./fast-corners
      FAST ( 300 x  168), keypoints: 557, time:0.487192 cpu
      [ WARN:0] Using world accessible cache directory. This may be not secure: /var/tmp/
      FAST ( 300 x  168), keypoints: 557, time:6.319238 gpu
      

      And it says GPU is too much slower than CPU. And I also got slower result compare to CPU.
      Is it expected output? And What kinds of situations GPU is faster than CPU?
      Thank you for your any advices!

      1 Reply Last reply Reply Quote 0
      • C
        Chad Sweet ModalAI Team
        last edited by 26 Jan 2023, 02:56

        That docker example is for VOXL 1. You should not use a Docker on VOXL 2 to access the GPU

        1 Reply Last reply Reply Quote 0
        • G
          Gyeongmin Kim
          last edited by Gyeongmin Kim 26 Jan 2023, 17:08 26 Jan 2023, 16:21

          Thank you for reply Chad!
          I already can run the example without docker.
          My question is why GPU is slower than CPU in the result of image.
          I am using opencv-opencl for my application. But I also got the result that GPU takes much time than CPU

          1 Reply Last reply Reply Quote 0
          • ?
            A Former User
            last edited by 26 Jan 2023, 18:55

            How are you timing the result, it can be an expensive operation to move the image memory from the cpu to the gpu and back, so it's not uncommon for the entire process to take longer using the gpu if you're copying large quantities of data back and forth even if the main processing you're doing is faster.

            1 Reply Last reply Reply Quote 0
            • G
              Gyeongmin Kim
              last edited by 27 Jan 2023, 18:51

              Thank you Alex!
              According to your reply, Should I use the gpu for large tasks such as Neural Network or large image instead of the task that need to process each frames?

              1 Reply Last reply Reply Quote 0
              1 out of 5
              • First post
                1/5
                Last post
              Powered by NodeBB | Contributors