plot_model¶
- opstool.vis.plotly.plot_model(odb_tag=None, show_node_numbering=False, show_ele_numbering=False, show_ele_hover=True, style='surface', color=None, show_bc=True, bc_scale=1.0, show_link=True, show_mp_constraint=True, show_constraint_dofs=False, show_nodal_loads=False, show_ele_loads=False, load_scale=1.0, show_local_axes=False, local_axes_scale=1.0, show_outline=True)[source]¶
Geometric model visualization based on
plotly.- Return type:
Figure
Parameters¶
- odb_tag: Union[int, str], default: None
Tag of output databases (ODB) to be visualized. If None, data will be extracted from the current running memory..
- show_node_numbering: bool, default: False
Whether to display node tag labels.
- show_ele_numbering: bool, default: False
Whether to display element tag labels.
- show_ele_hover: bool, default: True
Whether to display element tag labels when hovering over the element.
- style: str, default: surface
Visualization mesh style of surfaces and solids. One of the following: style=’surface’ or style=’wireframe’ Defaults to ‘surface’. Note that ‘wireframe’ only shows a wireframe of the outer geometry.
- color: str, default: black
Model display color.
- show_bc: bool, default: True
Whether to display boundary supports.
- bc_scale: float, default: 1.0
Scale the size of boundary support display.
- show_link: bool, default: True
Whether to show link elements.
- show_mp_constraint: bool, default: True
Whether to show multipoint (MP) constraint.
- show_constraint_dofs: bool, default: False
Whether to show dofs of mp-constraints.
- show_nodal_loads: bool, default: False
Whether to show nodal loads.
- show_ele_loads: bool, default: False
Whether to show element loads.
- load_scale: float, default: 1.0
Scale the size of load arrow presentation.
- show_local_axes: bool, default: False
Whether to display element local axes, including
beam-column,link, andshellelements.- local_axes_scale: float, default: 1.0
Scales the presentation size of the local axes.
- show_outline: bool, default: False
Whether to display the outline of the model.
Returns¶
- fig: plotly.graph_objects.Figure
You can use fig.show() to display, You can also use fig.write_html(“path/to/file.html”) to save as an HTML file, see Interactive HTML Export in Python