mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 12:20:52 +01:00
Remove Incorrect Comment in tools/build_libtorch and remove Python2 support in the module import (#44888)
Summary:
Fixes #{44293} and removes Python2 imports from MNIST download module as Python2 is not being supported.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/44888
Reviewed By: agolynski
Differential Revision: D23785579
Pulled By: bugra
fbshipit-source-id: d9380502380876282008dd2d5feb92a446648982
This commit is contained in:
parent
07b7e44ed1
commit
cff0e57c31
|
|
@ -8,9 +8,6 @@ import sys
|
|||
pytorch_root = dirname(dirname(abspath(__file__)))
|
||||
sys.path.append(pytorch_root)
|
||||
|
||||
# If you want to modify flags or environmental variables that is set when
|
||||
# building torch, you should do it in tools/setup_helpers/configure.py.
|
||||
# Please don't add it here unless it's only used in LibTorch.
|
||||
from tools.build_pytorch_libs import build_caffe2
|
||||
from tools.setup_helpers.cmake import CMake
|
||||
|
||||
|
|
|
|||
|
|
@ -1,18 +1,10 @@
|
|||
from __future__ import division
|
||||
from __future__ import print_function
|
||||
|
||||
import argparse
|
||||
import gzip
|
||||
import os
|
||||
from urllib.error import URLError
|
||||
from urllib.request import urlretrieve
|
||||
import sys
|
||||
|
||||
try:
|
||||
from urllib.error import URLError
|
||||
from urllib.request import urlretrieve
|
||||
except ImportError:
|
||||
from urllib2 import URLError
|
||||
from urllib import urlretrieve
|
||||
|
||||
MIRRORS = [
|
||||
'http://yann.lecun.com/exdb/mnist/',
|
||||
'https://ossci-datasets.s3.amazonaws.com/mnist/',
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user