Closed wardhaddadin1 closed 4 months ago
Here is a little benchmark:
On a pos = 5 * torch.randn(1000, 3), I get:
pos = 5 * torch.randn(1000, 3)
primitive_neighbor_list_torch
physicsml
from torch_nl import compute_neighborlist
from matscipy.neighbours import neighbour_list
If we include PBCs, it's:
To fix this:
torch-nl
That looks great. Thanks for the quick fix!
Here is a little benchmark:
On a
pos = 5 * torch.randn(1000, 3)
, I get:primitive_neighbor_list_torch
fromphysicsml
=> time ~0.39s (mean of 10 iters)from torch_nl import compute_neighborlist
, time ~ 0.07s (mean of 10)from matscipy.neighbours import neighbour_list
, time ~ 0.05s (mean of 10)If we include PBCs, it's:
primitive_neighbor_list_torch
fromphysicsml
=> time ~0.4s (mean of 10 iters)from torch_nl import compute_neighborlist
, time ~ 0.09s (mean of 10)from matscipy.neighbours import neighbour_list
, time ~ 0.09s (mean of 10)To fix this:
torch-nl
implementation when we have pbcs. (From here: https://github.com/felixmusil/torch_nl)