Skip to content

Commit

Permalink
Fix wrong import
Browse files Browse the repository at this point in the history
  • Loading branch information
woctezuma committed Jan 21, 2021
1 parent 4a2a7a0 commit d8df4c2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions build_feature_index.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import numpy as np
from generic_utils import load_image
from PIL import Image as pil_image
from PIL import ImageOps as pil_imageops

from app_id_utils import freeze_app_ids, list_app_ids, app_id_to_image_filename
from data_utils import get_label_database_filename
Expand Down Expand Up @@ -48,9 +48,9 @@ def build_feature_index(
image_filename = app_id_to_image_filename(app_id, is_horizontal_banner)
image = load_image(image_filename, target_size=target_model_size)
if apply_flip:
image = pil_image.flip(image)
image = pil_imageops.flip(image)
if apply_mirror:
image = pil_image.mirror(image)
image = pil_imageops.mirror(image)
features = convert_image_to_features(image, model, preprocess=preprocess)

Y_hat[counter, :] = features
Expand Down

0 comments on commit d8df4c2

Please sign in to comment.