neural_lam.plot_graph
=====================

.. py:module:: neural_lam.plot_graph

.. autoapi-nested-parse::

   Command-line utility for plotting saved Neural-LAM graphs.



Attributes
----------

.. autoapisummary::

   neural_lam.plot_graph.GRID_HEIGHT
   neural_lam.plot_graph.MESH_HEIGHT
   neural_lam.plot_graph.MESH_LEVEL_DIST


Functions
---------

.. autoapisummary::

   neural_lam.plot_graph.main
   neural_lam.plot_graph.plot_graph


Module Contents
---------------

.. py:function:: main() -> None

   Plot graph structure in 3D using plotly.


.. py:function:: plot_graph(grid_pos: numpy.ndarray, hierarchical: bool, graph_ldict: dict[str, Any], show_axis: bool = False, save: str | None = None) -> plotly.graph_objects.Figure

   Build a 3D plotly figure of the graph structure.

   :param grid_pos: Grid node positions, shape (num_grid_nodes, 2).
   :type grid_pos: np.ndarray
   :param hierarchical: Whether the loaded graph is hierarchical.
   :type hierarchical: bool
   :param graph_ldict: Graph dict as returned by ``utils.load_graph``.
   :type graph_ldict: dict
   :param show_axis: If True, show the 3D axis.
   :type show_axis: bool
   :param save: If given, save the figure as an HTML file at this path.
   :type save: str or None

   :returns: The plotly figure object.
   :rtype: go.Figure


.. py:data:: GRID_HEIGHT
   :value: 0


.. py:data:: MESH_HEIGHT
   :value: 0.1


.. py:data:: MESH_LEVEL_DIST
   :value: 0.2


