plot_animated_field#
- PostProcessorIcepak.plot_animated_field(quantity: str, assignment: str | list[str], plot_type: str = 'Surface', setup: str | None = None, intrinsics: str | dict[str, str] | None = None, variation_variable: str = 'Phi', variations: list[str] | None = None, view: str = 'isometric', show: bool = True, scale_min: float | None = None, scale_max: float | None = None, plot_cad_objs: bool = True, log_scale: bool = True, zoom: float | None = None, export_gif: bool = False, export_path: str = '', force_opacity_value: float = 0.1, dark_mode: bool = False, show_grid: bool = False, show_bounding: bool = False, show_legend: bool = True, filter_objects: list[str] | None = None, file_format: str = 'case')#
Create an animated field plot using Python PyVista and export to a gif file.
Note
The PyVista module rebuilds the mesh and the overlap fields on the mesh.
- Parameters:
- quantity
str Quantity to plot (for example,
"Mag_E").- assignment
list,str One or more objects or faces to apply the field plot to.
- plot_type
str,optional Plot type. The default is
Surface. Options are"CutPlane","Surface", and"Volume".- setup
str,optional Setup and sweep name on which create the field plot. Default is None for nominal setup usage.
- intrinsics
dict,str,optional Intrinsic variables required to compute the field before the export. These are typically: frequency, time and phase. It can be provided either as a dictionary or as a string. If it is a dictionary, keys depend on the solution type and can be expressed as: -
"Freq"or"Frequency"-"Time"-"Phase"If it is a string, it can either be
"Freq"or"Time"depending on the solution type. The default isNonein which case the intrinsics value is automatically computed based on the setup.- variation_variable
str,optional Variable to vary. The default is
"Phi".- variations
list,optional List of variation values with units. The default is
["0deg"].- view
str,optional View to export. Options are
"isometric","xy","xz","yz".- showbool,
optional Export Image without plotting on UI.
- scale_min
float,optional Fix the Scale Minimum value.
- scale_max
float,optional Fix the Scale Maximum value.
- plot_cad_objsbool,
optional Whether to include objects in the plot. The default is
True.- log_scalebool,
optional Whether to plot fields in log scale. The default is
True.- zoom
float,optional Zoom factor.
- export_gifbool,
optional Whether to export an animated gif or not. The default is
False.- export_path
str,optional Image export path. Default is
Noneto notworking_directorywill be used to save the image.- force_opacity_value
float,optional Opacity value between 0 and 1 to be applied to all model. If None aedt opacity will be applied to each object.
- dark_modebool,
optional Whether to display the model in dark mode or not. The default is
False.- show_gridbool,
optional Whether to display the axes grid or not. The default is
False.- show_boundingbool,
optional Whether to display the axes bounding box or not. The default is
False.- show_legendbool,
optional Whether to display the legend or not. The default is
True.- filter_objects
list,optional Objects list for filtering the
CutPlaneplots. The default isNonein which case an empty list is passed.- file_format
str,optional File format for the exported image. The default is
"case".
- quantity
- Returns:
ansys.aedt.core.generic.plot.ModelPlotterModel Object.