-
Notifications
You must be signed in to change notification settings - Fork 1
/
datasets.py
79 lines (57 loc) · 2.07 KB
/
datasets.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#!/usr/bin/env python
# coding: utf-8
# Imports
import globals
import os
# Call function MNIST
def MNIST():
# Path data_train_images
data_train_images = 'Datasets/MNIST/Dataset/Train/'
# Path data_test_images
data_test_images = 'Datasets/MNIST/Dataset/Test/'
return data_train_images, data_test_images
# Call function JAFFE
def JAFFE():
# Path data_train_images
data_train_images = 'Datasets/JAFFE/Dataset/Train/'
# Path data_test_images
data_test_images = 'Datasets/JAFFE/Dataset/Test/'
return data_train_images, data_test_images
# Call function extendedCK
def extendedCK():
# Path data_train_images
data_train_images = 'Datasets/Extended-CK+/Dataset/Train/'
# Path data_test_images
data_test_images = 'Datasets/Extended-CK+/Dataset/Test/'
return data_train_images, data_test_images
# Call function FEI
def FEI():
# Path data_train_images
data_train_images = 'Datasets/FEI/Dataset/Train/'
# Path data_test_images
data_test_images = 'Datasets/FEI/Dataset/Test/'
return data_train_images, data_test_images
# Call function CIFAR10
def CIFAR10():
# Path data_train_images
data_train_images = 'Datasets/CIFAR-10/Dataset/Train/'
# Path data_test_images
data_test_images = 'Datasets/CIFAR-10/Dataset/Test/'
return data_train_images, data_test_images
# Call function FER2013
def FER2013():
# Path data_train_images
data_train_images = 'Datasets/FER-2013/Dataset/Train/'
# Path data_test_images
data_test_images = 'Datasets/FER-2013/Dataset/Test/'
return data_train_images, data_test_images
# Call function printTrainingPath
def printTrainingPath():
print('Training-set path: %s\n' % globals.data_train_images, file = globals.file)
# Call function printTestPath
def printTestPath():
print('Test-set path: %s\n' % globals.data_test_images, file = globals.file)
# Call function printNumberOfClasses
def printNumberOfClasses():
globals.num_classes = len(os.listdir(globals.data_train_images))
print('Number of Classes: %i\n' % globals.num_classes, file = globals.file)