EPFL-VILAB / omnidata

A Scalable Pipeline for Making Steerable Multi-Task Mid-Level Vision Datasets from 3D Scans [ICCV 2021]
Other
418 stars 53 forks source link

Syntax Error in download code #2

Closed RealAntonVoronov closed 2 years ago

RealAntonVoronov commented 2 years ago

When I run

omnitools.download all --components taskonomy --subset fullplus --dest ./omnidata_starter_dataset/ --connections_total 40 --agree I get

Traceback (most recent call last): File "/home/jovyan/.imgenv-voronov-taskonomy-3-0/bin/omnitools.download", line 5, in from omnidata_tools.dataset.download import download File "/home/jovyan/.imgenv-voronov-taskonomy-3-0/lib/python3.7/site-packages/omnidata_tools/dataset/download.py", line 129 while (max_tries_per_model := max_tries_per_model-1) > 0: ^ SyntaxError: invalid syntax

alexsax commented 2 years ago

Which version of Python are you using? Looks like the offending line uses the walrus operator, which (I think) was added in 3.8

RealAntonVoronov commented 2 years ago

Thanks for quick answer. It's python 3.7.12. I have changed this part of code manually and found another incompatibility with my version of python

File "/home/jovyan/.imgenv-voronov-taskonomy-3-0/lib/python3.7/site-packages/omnidata_tools/dataset/metadata.py", line 46, in RemoteStorageMetadata @functools.cached_property
AttributeError: module 'functools' has no attribute 'cached_property'

Does your tool work only with Python 3.8? I have not found this requirement in the docs.

alexsax commented 2 years ago

Yes the tool should only work with python 3.8 and up. It shouldn't be hard to make it work with 3.7--pull requests are definitely appreciated :)