You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found the grid sample in pytorch is very fast. Maybe the opearation can be done in 1ms. In contrast, this one is quiet slow, costing several mintes! Any suggestions? Tks!
The text was updated successfully, but these errors were encountered:
Because pytorch grid sample is written in C++ and I think also it was using multi-threading. I have changed their C++ code and build only zero padding for grid sample. Below is the binary file.
You can load this binary file and use it with torch library:
import torch
torch.ops.load_library("my_grid_sampler.cpython-36m-x86_64-linux-gnu.so")
#Call the function
torch.ops.mynamespace.my_grid_sampler(image, grid)
I found the grid sample in pytorch is very fast. Maybe the opearation can be done in 1ms. In contrast, this one is quiet slow, costing several mintes! Any suggestions? Tks!
The text was updated successfully, but these errors were encountered: