code: def write_file(self, filename):
          
          with open(filename, "w") as f:
              f.write(self.__str__())
docs: Write the PWSCF input file.
  
          Args:
              filename (str): The string filename to output to.