diff --git a/setup.py b/setup.py index 04e87ac..c8ec379 100644 --- a/setup.py +++ b/setup.py @@ -2,14 +2,16 @@ about = {} # type: ignore -with open('torchgpipe/__about__.py') as f: +with open('torchgpipe/__version__.py') as f: exec(f.read(), about) # pylint: disable=W0122 +version = about['__version__'] +del about setup( name='torchgpipe', - version=about['__version__'], + version=version, license='Apache License 2.0', url='https://github.com/kakaobrain/torchgpipe', diff --git a/torchgpipe/__init__.py b/torchgpipe/__init__.py index 6e96017..b18c502 100644 --- a/torchgpipe/__init__.py +++ b/torchgpipe/__init__.py @@ -1,5 +1,5 @@ """A GPipe implementation in PyTorch.""" -from torchgpipe.__about__ import __version__ # noqa +from torchgpipe.__version__ import __version__ # noqa from torchgpipe.gpipe import GPipe __all__ = ['GPipe'] diff --git a/torchgpipe/__about__.py b/torchgpipe/__version__.py similarity index 100% rename from torchgpipe/__about__.py rename to torchgpipe/__version__.py