Skip to content
Snippets Groups Projects
Commit 1db4865e authored by Tiago de Freitas Pereira's avatar Tiago de Freitas Pereira
Browse files

Added support to the new bob.extension global config. Added the variables...

Added support to the new bob.extension global config. Added the variables facenet_modelpath and drgan_modelpath to the bobrc
parent 93cb3528
Branches
Tags
1 merge request!5Added support to the new bob.extension global config. Added the variables…
Pipeline #
...@@ -5,8 +5,7 @@ ...@@ -5,8 +5,7 @@
import numpy import numpy
import tensorflow as tf import tensorflow as tf
import os import os
import bob.ip.base from bob.extension import rc
import pkg_resources
from . import download_file from . import download_file
import logging import logging
logger = logging.getLogger(__name__) logger = logging.getLogger(__name__)
...@@ -332,7 +331,7 @@ class DrGanMSUExtractor(object): ...@@ -332,7 +331,7 @@ class DrGanMSUExtractor(object):
""" """
def __init__(self, model_path=None, image_size=[96, 96, 3]): def __init__(self, model_path=rc["drgan_modelpath"], image_size=[96, 96, 3]):
self.image_size = image_size self.image_size = image_size
self.session = tf.Session() self.session = tf.Session()
......
...@@ -7,6 +7,8 @@ import tensorflow as tf ...@@ -7,6 +7,8 @@ import tensorflow as tf
from bob.ip.color import gray_to_rgb from bob.ip.color import gray_to_rgb
from bob.io.image import to_matplotlib from bob.io.image import to_matplotlib
from . import download_file from . import download_file
from bob.extension import rc
logger = logging.getLogger(__name__) logger = logging.getLogger(__name__)
...@@ -72,7 +74,7 @@ class FaceNet(object): ...@@ -72,7 +74,7 @@ class FaceNet(object):
""" """
def __init__(self, def __init__(self,
model_path=None, model_path=rc["facenet_modelpath"],
image_size=160, image_size=160,
**kwargs): **kwargs):
super(FaceNet, self).__init__() super(FaceNet, self).__init__()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment