Skip to content

Commit

Permalink
Add __version__
Browse files Browse the repository at this point in the history
  • Loading branch information
sarlinpe committed Jan 1, 2022
1 parent 5c96289 commit faaac10
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 2 additions & 0 deletions hloc/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import logging
import sys

__version__ = '1.1'

logging.basicConfig(stream=sys.stdout,
format='[%(asctime)s %(levelname)s] %(message)s',
datefmt='%m/%d/%Y %H:%M:%S',
Expand Down
7 changes: 5 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@

description = ['Tools and baselines for visual localization and mapping']

with open(str(Path(__file__).parent / 'README.md'), 'r', encoding='utf-8') as f:
root = Path(__file__).parent
with open(str(root / 'README.md'), 'r', encoding='utf-8') as f:
readme = f.read()
with open(str(root / 'hloc/__init__.py'), 'r') as f:
version = eval(f.read().split('__version__ = ')[1].split()[0])

dependencies = [
'torch>=1.1',
Expand All @@ -20,7 +23,7 @@

setup(
name='hloc',
version='1.1',
version=version,
packages=['hloc'],
python_requires='>=3.6',
install_requires=dependencies,
Expand Down

0 comments on commit faaac10

Please sign in to comment.