title: How to write Jinja2 template for Jupyter nbconvert to show markdown and suppress output number?
body: <p>I am trying to write a <code>Jinja2</code> template to convert my <code>Jupyter notebook</code> to a PDF via <code>LaTex</code> using <code>nbconvert</code>. My current attempt does not show Markdown cells or image captions and also shows the following output above all of my matplotlib graphs:</p>
  
  <pre><code>out[1]: &lt;matplotlib.axes._subplots.AxesSubplot at 0x2e62e885cc0&gt;
  </code></pre>
  
  <p>I would like to display markdown cells and captions and to suppress matplotlib object descriptions. </p>
  
  <p>My current template is adapted from one hosted on the nbconvert github repo and is as follows:</p>
  
  <pre><code>% Default to the notebook output style
  ((* if not cell_style is defined *))
      ((* set cell_style = 'style_ipython.tplx' *))
  ((* endif *))
  
  % Inherit from the specified cell style.
  ((* extends cell_style *))
  
  
  %===============================================================================
  % Latex Book
  %===============================================================================
  
  ((* block docclass *))
  \documentclass{report}
  ((* endblock docclass *))
  
  % Author and Title from metadata
  ((* block maketitle *))
  ((*- if nb.metadata["latex_metadata"]: -*))
  ((*- if nb.metadata["latex_metadata"]["title"]: -*))
      \title{((( nb.metadata["latex_metadata"]["title"] )))}
  ((*- endif *))
  ((*- else -*))
      \title{((( resources.metadata.name )))}
  ((*- endif *))
  
  \date{\today}
  \maketitle
  ((* endblock maketitle *))
  
  ((* block markdowncell scoped *))
  ((( cell.source | citation2latex | strip_files_prefix | convert_pandoc('markdown+tex_math_double_backslash', 'json',extra_args=[]) | resolve_references | convert_pandoc('json','latex', extra_args=["--chapters"]) )))
  ((* endblock markdowncell *))
  
  
  % Disable input cells
  ((* block input_group *))
  ((* endblock input_group *))
  </code></pre>