Forum

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Ahmed Maher

Pages: [1]
1
Python and Java API / Python API Doesn't Use GPU for pickPoint
« on: February 10, 2022, 03:57:00 PM »
Hello All,

I am using Metashape Pro's Python API to get the geo-coordinate of each pixel inside the input images (by input images I mean images captured by the physical camera). I reused code already found on this forum. However, when I have a mesh with a large number of faces, I found that chunk.model.pickPoint takes ~ 30 ms per point on a somewhat powerful machine. This makes it totally unusable for a large number of pixels. When I checked the CPU and GPU usage, I found that the GPU is never used even if I explicitly change the GPU mask inside the script while the CPU usage is 100%. As far as I know, the pickPoint function is a ray intersection algorithm that should benefit dramatically from a GPU (the machine has an RTX GPU too). So, how can I make the Python API use the GPU for pickPoint? Is it not currently supported? If it is not supported on Python, is it supported inside the Java API?

Pages: [1]