code: def _write_header(self):
          
          for line in self.header.lines:
              print(line.serialize(), file=self.stream)
          if self.header.samples.names:
              print(
                  "\t".join(list(parser.REQUIRE_SAMPLE_HEADER) + self.header.samples.names),
                  file=self.stream,
              )
          else:
              print("\t".join(parser.REQUIRE_NO_SAMPLE_HEADER), file=self.stream)
docs: Write out the header