          with open(filename, "rb") as dfl:
              header = dfl.read(8)
              if header != b"\x89PNG\r\n\x1a\n":
                  print("ERROR: No Valid PNG header: {}".format(filename))
                  return
              while True:
                  chunk_start = dfl.tell()
                  chunk_hdr = dfl.read(8)
                  if not chunk_hdr:
                      break
 
</s> remove     def validate_dfl(self, face, frames):
        """ Validate that current file is good for dfl extraction """
        if face[1] != ".png":
            if self.verbose:
                print("{} is not a png. Skipping".format(face[0] + face[1]))
            return False
        if face[2] not in frames.keys():
            if self.verbose:
                print("{} does not have a matching source frame for {} in "
                      "frames directory. Skipping".format(face[0] + face[1],
                                                          face[2]))
            return False
        return True

 </s> add  </s> remove     def convert_dfl_alignment(dfl_alignments, sourcefile, alignments):
 </s> add     def convert_dfl_alignment(dfl_alignments, alignments): </s> remove             sourcefile = face[2] + frames[face[2]]
            self.convert_dfl_alignment(dfl, sourcefile, alignments)
 </s> add             self.convert_dfl_alignment(dfl, alignments) </s> remove             if not self.validate_dfl(face, frames):
 </s> add             if face[1] != ".png":
                if self.verbose:
                    print("{} is not a png. "
                          "Skipping".format(face[0] + face[1]))
                return None
          with open(filename, "rb") as dfl:
              header = dfl.read(8)
              if header != b"\x89PNG\r\n\x1a\n":
                  print("ERROR: No Valid PNG header: {}".format(filename))
                return None
              while True:
                  chunk_start = dfl.tell()
                  chunk_hdr = dfl.read(8)
                  if not chunk_hdr:
                      break
keep keep keep keep replace keep keep keep keep keep
 Small fix for alignments tool (#489)

* Remove frames requirement for dfl 
tools/alignments.py