mirror of
https://github.com/iperov/DeepFaceLab.git
synced 2025-07-16 10:03:41 -07:00
Extractor: 2nd pass now faster on frames where faces are not found
This commit is contained in:
parent
8305832a27
commit
9312a3c334
1 changed files with 5 additions and 3 deletions
|
@ -110,8 +110,11 @@ class ExtractSubprocessor(Subprocessor):
|
||||||
#override
|
#override
|
||||||
def process_data(self, data):
|
def process_data(self, data):
|
||||||
filename_path = Path( data.filename )
|
filename_path = Path( data.filename )
|
||||||
|
|
||||||
filename_path_str = str(filename_path)
|
filename_path_str = str(filename_path)
|
||||||
|
|
||||||
|
if self.type == 'landmarks' and len(data.rects) == 0:
|
||||||
|
return data
|
||||||
|
|
||||||
if self.cached_image[0] == filename_path_str:
|
if self.cached_image[0] == filename_path_str:
|
||||||
image = self.cached_image[1] #cached image for manual extractor
|
image = self.cached_image[1] #cached image for manual extractor
|
||||||
else:
|
else:
|
||||||
|
@ -164,7 +167,6 @@ class ExtractSubprocessor(Subprocessor):
|
||||||
return data
|
return data
|
||||||
|
|
||||||
elif self.type == 'landmarks':
|
elif self.type == 'landmarks':
|
||||||
|
|
||||||
if data.rects_rotation == 0:
|
if data.rects_rotation == 0:
|
||||||
rotated_image = image
|
rotated_image = image
|
||||||
elif data.rects_rotation == 90:
|
elif data.rects_rotation == 90:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue