Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
vision
Commits
99ace645
Commit
99ace645
authored
Dec 24, 2016
by
Soumith Chintala
Committed by
GitHub
Dec 24, 2016
Browse files
Merge pull request #18 from rtqichen/master
python 3 fix for cifar test sets.
parents
b733ad1a
486839ed
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
torchvision/datasets/cifar.py
torchvision/datasets/cifar.py
+4
-1
No files found.
torchvision/datasets/cifar.py
View file @
99ace645
...
...
@@ -66,7 +66,10 @@ class CIFAR10(data.Dataset):
f
=
self
.
test_list
[
0
][
0
]
file
=
os
.
path
.
join
(
root
,
self
.
base_folder
,
f
)
fo
=
open
(
file
,
'rb'
)
entry
=
pickle
.
load
(
fo
)
if
sys
.
version_info
[
0
]
==
2
:
entry
=
pickle
.
load
(
fo
)
else
:
entry
=
pickle
.
load
(
fo
,
encoding
=
'latin1'
)
self
.
test_data
=
entry
[
'data'
]
if
'labels'
in
entry
:
self
.
test_labels
=
entry
[
'labels'
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment