-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support torch tensors #7
Changes from all commits
cc6902d
91d7144
6391de4
dc1ac17
d424d22
a9c39c4
4d1e603
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,13 +32,20 @@ def read_version(): | |
'pytest<5.0', | ||
'numpy', | ||
] | ||
if sys.version_info >= (3, 5): | ||
tests_requires += ['torch', 'torchvision'] | ||
|
||
if sys.version_info >= (3, 6): | ||
tests_requires += ['matplotlib>=3.1', 'Pillow'] | ||
elif sys.version_info >= (3, 5): | ||
tests_requires += ['matplotlib~=3.0.3', 'Pillow'] | ||
else: # <= Python 3.4 | ||
tests_requires += ['matplotlib<3.0', 'Pillow<6.0'] | ||
|
||
# pytorch: python 2.7 require future | ||
if sys.version_info < (3, 0): | ||
tests_requires += ['future'] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could you please elaborate on why future is needed? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. python2.7 import error. see. root@1f2b2ea83553:~# pip install torch
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Collecting torch
Downloading torch-1.4.0-cp27-cp27mu-manylinux1_x86_64.whl (753.4 MB)
|████████████████████████████████| 753.4 MB 2.5 kB/s
Installing collected packages: torch
Successfully installed torch-1.4.0
root@1f2b2ea83553:~# python
Python 2.7.17 (default, Feb 26 2020, 17:18:08)
[GCC 8.3.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.7/site-packages/torch/__init__.py", line 19, in <module>
from ._six import string_classes as _string_classes
File "/usr/local/lib/python2.7/site-packages/torch/_six.py", line 23, in <module>
import builtins
ImportError: No module named builtins |
||
|
||
__version__ = read_version() | ||
|
||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you fix grammar issues here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is grammar issues?