rdyro / torch2jax

Wraps PyTorch code in a JIT-compatible way for JAX. Supports automatically defining gradients for reverse-mode AutoDiff.
https://rdyro.github.io/torch2jax/
MIT License
37 stars 1 forks source link

Handling situation of having two identically named packages #9

Closed adam-hartshorne closed 11 months ago

adam-hartshorne commented 1 year ago

Given there are now two "torch2jax" packages, obviously, this makes it problematic if I want to install both and use them for slightly different purposes in the same virtual environment.

I am wondering what the way forward here is?

rdyro commented 1 year ago

Sorry for the delay, this is definitely a pressing issue, especially given pip's poor support for aliasing packages during installation.

I'm a little loath to find a new name, given that I believe this torch2jax stays much closer to the original jax2torch in its philosophy of wrapping jax in torch rather than rewriting jax in torch. However, given this and the fact that the other torch2jax is already in PyPI, I don't think there's any other course of action than renaming this packages.

I'm actively thinking of a name change and I will act on this (with minimal breaking changes) by the end of this week.

rdyro commented 1 year ago

I apologize for not having a solution yet, a stopgap solution is now mentioned in the README.md under Related Work. I provide a helper script to install this package under an aliased named, see:

rdyro commented 11 months ago

The aliased PyPI installation is now available!

$ pip install wrap-torch2jax
$ # then
$ python3
$ >>> from wrap_torch2jax import torch2jax, torch2jax_with_vjp

@adam-hartshorne