class_docstr: An Htmlbook is used to generate an html page from text and matplotlib figures.
class_docstr_tok: ["An","Htmlbook","is","used","to","generate","an","html","page","from","text","and","matplotlib","figures","."]
docstr: Initializes Htmlbook with a given title.
docstr_tok: ["Initializes","Htmlbook","with","a","given","title","."]
code: def __init__(self, title):
      """Initializes Htmlbook with a given title."""
      # The doc is used for the body of the document
      self.doc, self.tag, self.text, self.line = Doc().ttl()
      # The top_doc is used for the title and table of contents
      (
          self.top_doc,
          self.top_tag,
          self.top_text,
          self.top_line,
      ) = Doc().ttl()
      # Add link anchor and title to the top_doc
      self.top_line("a", "", name="top")
      self.top_line("h1", title)
      self.section_counter = 1
  
file_path: pycls/pycls/sweep/htmlbook.py
imports: import base64
  from io import BytesIO
  import matplotlib.pyplot
  from yattag import Doc, indent
label_desc: Use image node_id 1 to create a new Htmlbook object  with example: obj = Htmlbook(title)