save_diagram_sets#

save_diagram_sets(filename, diagram_sets, notation='native', comment=None)#

Writes multiple sets of diagrams to a file at once.

Parameters:
  • filename – Path to the output file.

  • diagrams – A list of diagrams to write.

  • notation – The diagram notation (‘dowker’, ‘gauss’, etc.).

  • to_string_func – Function to convert diagrams into strings.

  • comment – (Optional) A comment to add at the start of the file.