balbasty / nitorch

Neuroimaging in PyTorch
Other
86 stars 14 forks source link

Fallback implementation of pull/push in pure python #26

Closed balbasty closed 3 years ago

balbasty commented 3 years ago

Since torch.index_put has an accumulate option, it is in theory possible to implement grid_push in pure pytorch. It is also possible to implement grid_pull using fancy indexing. Maybe we should do this so that the package can be used even without being compiled? (push/pull would be a lot slower, but we would use the compiled version when available).

This has a low priority.

balbasty commented 3 years ago

This was done in PR #56 , now merged.