As discussed in #20, it would be really practical to have these optimizers in a package. This PR makes that possible. ranger can be installed and imported in all python projects, no need to copy paste the ranger optimizer anymore. This also allows to give you proper credit where it is used (I'll add it in the requirements in asteroid for example).
I also updated the README with the install and usage instruction.
You can clone the repo, then install it with pip in editable mode (pretty practical for research) or not.
Note : In the __init__.py I imported the three optimizers so that they can be imported from the package directly (from ranger import RangerQH instead of from ranger.rangerqh import RangerQH). Both ranger.py and ranger913A.py had the same name for the class, so I changed the class in ranger913A.py to RangerVA (for versionA).
I'd like to here from you, this would be very practical to have it as a package.
Hi @mpariente,
Thanks a ton for this. I just responded on the other thread before seeing this linked in.
I'm merging it in now and thanks for fixing the naming collision. :)
It's a pleasure, thanks to you.
Just to be clear, this cannot be installed with pip just yet.
In order to pip install ranger, the package needs to be uploaded to PyPI but I added to instructions to install it from git in the README.
As discussed in #20, it would be really practical to have these optimizers in a package. This PR makes that possible.
ranger
can be installed and imported in all python projects, no need to copy paste the ranger optimizer anymore. This also allows to give you proper credit where it is used (I'll add it in the requirements inasteroid
for example).I also updated the README with the install and usage instruction. You can clone the repo, then install it with
pip
in editable mode (pretty practical for research) or not.Note : In the
__init__.py
I imported the three optimizers so that they can be imported from the package directly (from ranger import RangerQH
instead offrom ranger.rangerqh import RangerQH
). Bothranger.py
andranger913A.py
had the same name for the class, so I changed the class inranger913A.py
toRangerVA
(for versionA).I'd like to here from you, this would be very practical to have it as a package.