Spaces:
Sleeping
Sleeping
Update src/02_feature_extraction.py
Browse files
src/02_feature_extraction.py
CHANGED
|
@@ -10,15 +10,6 @@ import numpy as np
|
|
| 10 |
from tqdm import tqdm
|
| 11 |
from PIL import Image
|
| 12 |
from keras_vggface.utils import preprocess_input
|
| 13 |
-
from tensorflow.python.keras.utils.layer_utils import get_source_inputs
|
| 14 |
-
from tensorflow.python.keras.layers import (
|
| 15 |
-
Flatten, Dense, Input, GlobalAveragePooling2D,
|
| 16 |
-
GlobalMaxPooling2D, Activation, Conv2D, MaxPooling2D,
|
| 17 |
-
BatchNormalization, AveragePooling2D, Reshape, Permute, multiply
|
| 18 |
-
)
|
| 19 |
-
from tensorflow.python.keras.models import Model
|
| 20 |
-
from tensorflow.python.keras import backend as K
|
| 21 |
-
from tensorflow.python.keras.utils.data_utils import get_file
|
| 22 |
|
| 23 |
|
| 24 |
def extractor(img_path, model):
|
|
|
|
| 10 |
from tqdm import tqdm
|
| 11 |
from PIL import Image
|
| 12 |
from keras_vggface.utils import preprocess_input
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
|
| 14 |
|
| 15 |
def extractor(img_path, model):
|