Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
yusuke-a-uchida committed Aug 9, 2018
1 parent e07493f commit 2e9daf6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion age_estimation/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@ def get_transform_func():
p = Augmentor.Pipeline()
p.flip_left_right(probability=0.5)
p.rotate(probability=1, max_left_rotation=5, max_right_rotation=5)
p.zoom_random(probability=1, percentage_area=0.95)
p.zoom_random(probability=0.5, percentage_area=0.95)
p.random_distortion(probability=0.5, grid_width=2, grid_height=2, magnitude=8)
p.random_color(probability=1, min_factor=0.8, max_factor=1.2)
p.random_contrast(probability=1, min_factor=0.8, max_factor=1.2)
p.random_brightness(probability=1, min_factor=0.8, max_factor=1.2)

def transform_image(image):
image = [Image.fromarray(image)]
Expand Down

0 comments on commit 2e9daf6

Please sign in to comment.