"src/vscode:/vscode.git/clone" did not exist on "5f463f9b5a157e98beeb817879f0ac182934ca42"
Commit 08b1f59f authored by Jiren Jin's avatar Jiren Jin Committed by Soumith Chintala
Browse files

Create `ImageFolder` with the same (sorted) order on different machines (#193)

parent c1f88ef1
......@@ -24,7 +24,7 @@ def find_classes(dir):
def make_dataset(dir, class_to_idx):
images = []
dir = os.path.expanduser(dir)
for target in os.listdir(dir):
for target in sorted(os.listdir(dir)):
d = os.path.join(dir, target)
if not os.path.isdir(d):
continue
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment