b1cfbe458c0bf123591348c54973d49297fd55ab,tools/alignments/jobs.py,Extract,_output_faces,#Extract#Any#Any#,525

Before Change


        logger.trace("Outputting frame: %s", filename)
        face_count = 0
        frame_name = os.path.splitext(filename)[0]
        extension = ".png"
        faces = self._select_valid_faces(filename, image)
        if not faces:
            return face_count
        if self._is_legacy:
            faces = self._process_legacy(filename, image, faces)

        for idx, face in enumerate(faces):
            output = "{}_{}{}".format(frame_name, str(idx), extension)
            if self._arguments.large:
                self._frames.save_image(self._faces_dir, output, face.aligned.face)
            else:
                output = os.path.join(self._faces_dir, output)
                f_hash = self._extracted_faces.save_face_with_hash(output,
                                                                   extension,

After Change


        for idx, face in enumerate(faces):
            output = "{}_{}.png".format(frame_name, str(idx))
            meta = dict(alignments=face.to_png_meta(),
                        source=dict(alignments_version=self._alignments.version,
                                    original_filename=output,
                                    face_index=idx,
                                    source_filename=filename,
                                    source_is_video=self._frames.is_video))
            self._saver.save(output, encode_image(face.aligned.face, ".png", metadata=meta))
            if not self._arguments.large and self._is_legacy:
                face.thumbnail = generate_thumbnail(face.aligned.face, size=96, quality=60)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: deepfakes/faceswap
Commit Name: b1cfbe458c0bf123591348c54973d49297fd55ab
Time: 2021-02-14
Author: 36920800+torzdf@users.noreply.github.com
File Name: tools/alignments/jobs.py
Class Name: Extract
Method Name: _output_faces


Project Name: jakeret/tf_unet
Commit Name: 144641aad5289b7edef6195d21fb55dafd3f6187
Time: 2017-01-08
Author: jakeret@phys.ethz.ch
File Name: scripts/ufig_launcher.py
Class Name:
Method Name: launch


Project Name: jakeret/tf_unet
Commit Name: 144641aad5289b7edef6195d21fb55dafd3f6187
Time: 2017-01-08
Author: jakeret@phys.ethz.ch
File Name: scripts/rfi_launcher.py
Class Name:
Method Name: launch