Skip to content

Commit

Permalink
fixed a bug in domain adaptation code
Browse files Browse the repository at this point in the history
  • Loading branch information
mingyuliutw committed Oct 10, 2017
1 parent f42028d commit 4cd5de5
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/datasets/dataset_mnist.py
Expand Up @@ -45,8 +45,7 @@ def _load_samples(self, full_filepath):
# images = np.concatenate((images, images, images), axis=1)
if self.use_inversion == 1:
images = np.concatenate((images, 1 - images), axis=0)
images = 1 - images
labels = np.concatenate((labels, labels), axis=0)
labels = np.concatenate((labels, labels), axis=0)
images = (images - 0.5) * 2
return np.float32(images), labels

Expand Down Expand Up @@ -102,4 +101,4 @@ def _load_samples(self, full_filepath):
images = test_set[0]
labels = test_set[1]
images = (images - 0.5) * 2
return np.float32(images), labels
return np.float32(images), labels

0 comments on commit 4cd5de5

Please sign in to comment.