Skip to content

Commit

Permalink
small bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Hantian Zhang committed Aug 18, 2017
1 parent 21323cf commit 028737c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion config.py
Expand Up @@ -5,7 +5,7 @@ class Config:
output_path = "results"

img_size = 424
adjust_size = 500
adjust_size = 424
train_size = 424
img_channel = 3
conv_channel_base = 64
Expand Down
2 changes: 1 addition & 1 deletion train.py
Expand Up @@ -12,7 +12,7 @@ def prepocess_train(img, cond,):
img = scipy.misc.imresize(img, [conf.adjust_size, conf.adjust_size])
cond = scipy.misc.imresize(cond, [conf.adjust_size, conf.adjust_size])
h1 = int(np.ceil(np.random.uniform(1e-2, conf.adjust_size - conf.train_size)))
w1 = int(np.ceil(np.random.uniform(1e-2, conf.adjust_size - conf.adjust_size)))
w1 = int(np.ceil(np.random.uniform(1e-2, conf.adjust_size - conf.train_size)))
img = img[h1:h1 + conf.train_size, w1:w1 + conf.train_size]
cond = cond[h1:h1 + conf.train_size, w1:w1 + conf.train_size]
if np.random.random() > 0.5:
Expand Down

0 comments on commit 028737c

Please sign in to comment.