def generate_alignments(self): """ Generate an alignments file if one does not already exist. Does not save extracted faces """ print('Alignments file not found. Generating at default values...') extract = Extract(self.args) extract.export_face = False extract.process()
def extract(self, input_dir, output_dir, filter_path): extract = Extract(self._subparser, "extract", "Extract the faces from a pictures.") args_str = "extract --input-dir {} --output-dir {} --processes 1 --detector cnn --filter {}" args_str = args_str.format(input_dir, output_dir, filter_path) self._run_script(args_str)