ansys-fluent-visualization 0.17.dev0__tar.gz → 0.18.dev0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/LICENSE +7 -7
  2. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/PKG-INFO +1 -2
  3. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/pyproject.toml +1 -1
  4. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/__init__.py +64 -0
  5. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/_config.py +22 -0
  6. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/containers.py +22 -0
  7. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/contour.py +22 -0
  8. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/graphics/__init__.py +28 -0
  9. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/graphics/abstract_graphics_defns.py +66 -0
  10. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/graphics/graphics_objects.py +22 -0
  11. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/graphics/graphics_windows.py +22 -0
  12. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/graphics/graphics_windows_manager.py +22 -0
  13. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/graphics/pyvista/__init__.py +21 -0
  14. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/graphics/pyvista/graphics_defns.py +22 -0
  15. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/matplotlib/__init__.py +39 -0
  16. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/plotter/__init__.py +28 -0
  17. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/plotter/abstract_plotter_defns.py +73 -0
  18. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/plotter/matplotlib/__init__.py +21 -0
  19. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/plotter/matplotlib/plotter_defns.py +22 -0
  20. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/plotter/plotly/__init__.py +21 -0
  21. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/plotter/plotly/plotter_defns.py +22 -0
  22. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/plotter/plotter_objects.py +22 -0
  23. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/plotter/plotter_windows.py +22 -0
  24. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/plotter/plotter_windows_manager.py +22 -0
  25. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/plotter/pyvista/__init__.py +21 -0
  26. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/plotter/pyvista/plotter_defns.py +22 -0
  27. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/post_data_extractor.py +22 -0
  28. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/src/ansys/fluent/visualization/post_windows_manager.py +22 -0
  29. ansys_fluent_visualization-0.18.dev0/src/ansys/fluent/visualization/pyvista/__init__.py +39 -0
  30. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/__init__.py +0 -42
  31. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/graphics/__init__.py +0 -6
  32. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/graphics/abstract_graphics_defns.py +0 -44
  33. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/graphics/pyvista/__init__.py +0 -0
  34. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/matplotlib/__init__.py +0 -17
  35. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/plotter/__init__.py +0 -6
  36. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/plotter/abstract_plotter_defns.py +0 -51
  37. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/plotter/matplotlib/__init__.py +0 -0
  38. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/plotter/plotly/__init__.py +0 -0
  39. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/plotter/pyvista/__init__.py +0 -0
  40. ansys_fluent_visualization-0.17.dev0/src/ansys/fluent/visualization/pyvista/__init__.py +0 -17
  41. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/AUTHORS +0 -0
  42. {ansys_fluent_visualization-0.17.dev0 → ansys_fluent_visualization-0.18.dev0}/README.rst +0 -0
@@ -1,13 +1,13 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2022 ANSYS, Inc. All rights reserved.
3
+ Copyright (c) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
4
4
 
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
6
+ this software and associated documentation files (the "Software"), to deal in
7
+ the Software without restriction, including without limitation the rights to
8
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
9
+ of the Software, and to permit persons to whom the Software is furnished to do
10
+ so, subject to the following conditions:
11
11
 
12
12
  The above copyright notice and this permission notice shall be included in all
13
13
  copies or substantial portions of the Software.
@@ -1,8 +1,7 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: ansys-fluent-visualization
3
- Version: 0.17.dev0
3
+ Version: 0.18.dev0
4
4
  Summary: A python wrapper for ansys Fluent visualization
5
- Home-page: https://github.com/ansys/pyfluent-visualization
6
5
  License: MIT
7
6
  Author: ANSYS, Inc.
8
7
  Author-email: ansys.support@ansys.com
@@ -5,7 +5,7 @@ build-backend = "poetry.core.masonry.api"
5
5
  [tool.poetry]
6
6
  # Check https://python-poetry.org/docs/pyproject/ for all available sections
7
7
  name = "ansys-fluent-visualization"
8
- version = "0.17.dev0"
8
+ version = "0.18.dev0"
9
9
  description = "A python wrapper for ansys Fluent visualization"
10
10
  license = "MIT"
11
11
  authors = ["ANSYS, Inc. <ansys.support@ansys.com>"]
@@ -0,0 +1,64 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
23
+ """Python post processing integrations for the Fluent solver."""
24
+
25
+ try:
26
+ import importlib.metadata as importlib_metadata
27
+ except ModuleNotFoundError:
28
+ import importlib_metadata
29
+
30
+ _VERSION_INFO = "Build date: February 11, 2025 07:45 UTC ShaID: a0f6c2e"
31
+ __version__ = importlib_metadata.version(__name__.replace(".", "-"))
32
+ PLOTTER = "matplotlib"
33
+ INTERACTIVE = False
34
+
35
+
36
+ def version_info() -> str:
37
+ """Method returning the version of PyFluent being used.
38
+ Returns
39
+ -------
40
+ str
41
+ The PyFluent version being used.
42
+ Notes
43
+ -------
44
+ Only available in packaged versions. Otherwise it will return __version__.
45
+ """
46
+ return _VERSION_INFO if _VERSION_INFO is not None else __version__
47
+
48
+
49
+ from ansys.fluent.visualization._config import get_config, set_config # noqa: F401
50
+ from ansys.fluent.visualization.containers import ( # noqa: F401
51
+ Contour,
52
+ Mesh,
53
+ Monitor,
54
+ Pathline,
55
+ Surface,
56
+ Vector,
57
+ XYPlot,
58
+ )
59
+ from ansys.fluent.visualization.graphics import Graphics # noqa: F401
60
+ from ansys.fluent.visualization.graphics.graphics_windows import ( # noqa: F401
61
+ GraphicsWindow,
62
+ )
63
+ from ansys.fluent.visualization.plotter import Plots # noqa: F401
64
+ from ansys.fluent.visualization.plotter.plotter_windows import PlotterWindow
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Global configuration state for visualization."""
2
24
 
3
25
  _global_config = {"blocking": False, "set_view_on_display": None}
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Containers for graphics."""
2
24
 
3
25
  from ansys.fluent.visualization.graphics import Graphics
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Contour objects based on field name and surfaces list."""
2
24
 
3
25
  from typing import List, Optional
@@ -0,0 +1,28 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
23
+ """A package that provides interfacing Fluent with graphics renderer (PyVista)."""
24
+
25
+ from ansys.fluent.visualization.graphics.graphics_objects import Graphics # noqa: F401
26
+ from ansys.fluent.visualization.graphics.graphics_windows_manager import ( # noqa: F401
27
+ graphics_windows_manager,
28
+ )
@@ -0,0 +1,66 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
23
+ """Abstract module providing graphics functionality."""
24
+
25
+ from abc import ABC, abstractmethod
26
+
27
+
28
+ class AbstractRenderer(ABC):
29
+ """Abstract class for renderer."""
30
+
31
+ @abstractmethod
32
+ def show(self):
33
+ """Show graphics."""
34
+ pass
35
+
36
+ @abstractmethod
37
+ def render(self, mesh, **kwargs):
38
+ """Render graphics in window."""
39
+ pass
40
+
41
+ @abstractmethod
42
+ def save_graphic(self, file_name: str):
43
+ """Save graphics to the specified file.
44
+
45
+ Parameters
46
+ ----------
47
+ file_name : str
48
+ File name to save graphic.
49
+ """
50
+ pass
51
+
52
+ @abstractmethod
53
+ def get_animation(self, win_id: str):
54
+ """Animate windows.
55
+
56
+ Parameters
57
+ ----------
58
+ win_id : str
59
+ ID for the window to animate.
60
+ """
61
+ pass
62
+
63
+ @abstractmethod
64
+ def close(self):
65
+ """Close graphics window."""
66
+ pass
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module providing visualization objects for PyVista."""
2
24
 
3
25
  import sys
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """A wrapper to improve the user interface of graphics."""
2
24
 
3
25
  from ansys.fluent.visualization import get_config
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module for graphics windows management."""
2
24
 
3
25
  from enum import Enum
@@ -0,0 +1,21 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module for pyVista windows management."""
2
24
 
3
25
  import numpy as np
@@ -0,0 +1,39 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
23
+ """A DEPRECATED package that provides interfacing Fluent with plotters."""
24
+
25
+ import warnings
26
+
27
+ from ansys.fluent.core.pyfluent_warnings import PyFluentDeprecationWarning
28
+
29
+ warnings.warn(
30
+ "'matplotlib' is deprecated. Use 'plotter' instead.",
31
+ PyFluentDeprecationWarning,
32
+ )
33
+
34
+ from ansys.fluent.visualization.plotter.plotter_objects import Plots # noqa: F401
35
+ from ansys.fluent.visualization.plotter.plotter_windows_manager import ( # noqa: F401
36
+ plotter_windows_manager,
37
+ )
38
+
39
+ matplotlib_windows_manager = plotter_windows_manager
@@ -0,0 +1,28 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
23
+ """A package that provides interfacing Fluent with plotters (matplotlib or pyvista)."""
24
+
25
+ from ansys.fluent.visualization.plotter.plotter_objects import Plots # noqa: F401
26
+ from ansys.fluent.visualization.plotter.plotter_windows_manager import ( # noqa: F401
27
+ plotter_windows_manager,
28
+ )
@@ -0,0 +1,73 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
23
+ """Abstract module providing plotter functionality."""
24
+
25
+ from abc import ABC, abstractmethod
26
+
27
+
28
+ class AbstractPlotter(ABC):
29
+ """Abstract class for plotter."""
30
+
31
+ @abstractmethod
32
+ def plot(self, data: dict) -> None:
33
+ """Draw plot in window.
34
+
35
+ Parameters
36
+ ----------
37
+ data : dict
38
+ Data to plot. Data consists the list of x and y
39
+ values for each curve.
40
+ """
41
+ pass
42
+
43
+ @abstractmethod
44
+ def close(self):
45
+ """Close plotter window."""
46
+ pass
47
+
48
+ @abstractmethod
49
+ def is_closed(self):
50
+ """Check if the plotter window is closed."""
51
+ pass
52
+
53
+ @abstractmethod
54
+ def save_graphic(self, file_name: str):
55
+ """Save graphics to the specified file.
56
+
57
+ Parameters
58
+ ----------
59
+ file_name : str
60
+ File name to save graphic.
61
+ """
62
+ pass
63
+
64
+ @abstractmethod
65
+ def set_properties(self, properties: dict):
66
+ """Set plot properties.
67
+
68
+ Parameters
69
+ ----------
70
+ properties : dict
71
+ Plot properties i.e. curves, title, xlabel and ylabel.
72
+ """
73
+ pass
@@ -0,0 +1,21 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module providing matplotlib plotter functionality."""
2
24
 
3
25
  from typing import List, Optional
@@ -0,0 +1,21 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  import numpy as np
2
24
  import plotly.graph_objects as go
3
25
  from plotly.subplots import make_subplots
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module providing visualization objects for Matplotlib."""
2
24
 
3
25
  import sys
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  from ansys.fluent.visualization.plotter import plotter_windows_manager
2
24
 
3
25
 
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module for plotter windows management."""
2
24
 
3
25
  import itertools
@@ -0,0 +1,21 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  from typing import List, Optional
2
24
 
3
25
  import numpy as np
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module providing data extractor APIs."""
2
24
 
3
25
  import itertools
@@ -1,3 +1,25 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
1
23
  """Module providing PostWindow and PostWindowManager abstract classes.
2
24
 
3
25
  PostWindowManager is container for PostWindow.
@@ -0,0 +1,39 @@
1
+ # Copyright (C) 2022 - 2025 ANSYS, Inc. and/or its affiliates.
2
+ # SPDX-License-Identifier: MIT
3
+ #
4
+ #
5
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ # of this software and associated documentation files (the "Software"), to deal
7
+ # in the Software without restriction, including without limitation the rights
8
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ # copies of the Software, and to permit persons to whom the Software is
10
+ # furnished to do so, subject to the following conditions:
11
+ #
12
+ # The above copyright notice and this permission notice shall be included in all
13
+ # copies or substantial portions of the Software.
14
+ #
15
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ # SOFTWARE.
22
+
23
+ """A DEPRECATED package that provides interfacing Fluent with graphics renderer."""
24
+
25
+ import warnings
26
+
27
+ from ansys.fluent.core.pyfluent_warnings import PyFluentDeprecationWarning
28
+
29
+ warnings.warn(
30
+ "'pyvista' is deprecated. Use 'graphics' instead.",
31
+ PyFluentDeprecationWarning,
32
+ )
33
+
34
+ from ansys.fluent.visualization.graphics.graphics_objects import Graphics # noqa: F401
35
+ from ansys.fluent.visualization.graphics.graphics_windows_manager import ( # noqa: F401
36
+ graphics_windows_manager,
37
+ )
38
+
39
+ pyvista_windows_manager = graphics_windows_manager
@@ -1,42 +0,0 @@
1
- """Python post processing integrations for the Fluent solver."""
2
-
3
- try:
4
- import importlib.metadata as importlib_metadata
5
- except ModuleNotFoundError:
6
- import importlib_metadata
7
-
8
- _VERSION_INFO = "Build date: January 06, 2025 09:12 UTC ShaID: a7bfb72"
9
- __version__ = importlib_metadata.version(__name__.replace(".", "-"))
10
- PLOTTER = "matplotlib"
11
- INTERACTIVE = False
12
-
13
-
14
- def version_info() -> str:
15
- """Method returning the version of PyFluent being used.
16
- Returns
17
- -------
18
- str
19
- The PyFluent version being used.
20
- Notes
21
- -------
22
- Only available in packaged versions. Otherwise it will return __version__.
23
- """
24
- return _VERSION_INFO if _VERSION_INFO is not None else __version__
25
-
26
-
27
- from ansys.fluent.visualization._config import get_config, set_config # noqa: F401
28
- from ansys.fluent.visualization.containers import ( # noqa: F401
29
- Contour,
30
- Mesh,
31
- Monitor,
32
- Pathline,
33
- Surface,
34
- Vector,
35
- XYPlot,
36
- )
37
- from ansys.fluent.visualization.graphics import Graphics # noqa: F401
38
- from ansys.fluent.visualization.graphics.graphics_windows import ( # noqa: F401
39
- GraphicsWindow,
40
- )
41
- from ansys.fluent.visualization.plotter import Plots # noqa: F401
42
- from ansys.fluent.visualization.plotter.plotter_windows import PlotterWindow
@@ -1,6 +0,0 @@
1
- """A package that provides interfacing Fluent with graphics renderer (PyVista)."""
2
-
3
- from ansys.fluent.visualization.graphics.graphics_objects import Graphics # noqa: F401
4
- from ansys.fluent.visualization.graphics.graphics_windows_manager import ( # noqa: F401
5
- graphics_windows_manager,
6
- )
@@ -1,44 +0,0 @@
1
- """Abstract module providing graphics functionality."""
2
-
3
- from abc import ABC, abstractmethod
4
-
5
-
6
- class AbstractRenderer(ABC):
7
- """Abstract class for renderer."""
8
-
9
- @abstractmethod
10
- def show(self):
11
- """Show graphics."""
12
- pass
13
-
14
- @abstractmethod
15
- def render(self, mesh, **kwargs):
16
- """Render graphics in window."""
17
- pass
18
-
19
- @abstractmethod
20
- def save_graphic(self, file_name: str):
21
- """Save graphics to the specified file.
22
-
23
- Parameters
24
- ----------
25
- file_name : str
26
- File name to save graphic.
27
- """
28
- pass
29
-
30
- @abstractmethod
31
- def get_animation(self, win_id: str):
32
- """Animate windows.
33
-
34
- Parameters
35
- ----------
36
- win_id : str
37
- ID for the window to animate.
38
- """
39
- pass
40
-
41
- @abstractmethod
42
- def close(self):
43
- """Close graphics window."""
44
- pass
@@ -1,17 +0,0 @@
1
- """A DEPRECATED package that provides interfacing Fluent with plotters."""
2
-
3
- import warnings
4
-
5
- from ansys.fluent.core.warnings import PyFluentDeprecationWarning
6
-
7
- warnings.warn(
8
- "'matplotlib' is deprecated. Use 'plotter' instead.",
9
- PyFluentDeprecationWarning,
10
- )
11
-
12
- from ansys.fluent.visualization.plotter.plotter_objects import Plots # noqa: F401
13
- from ansys.fluent.visualization.plotter.plotter_windows_manager import ( # noqa: F401
14
- plotter_windows_manager,
15
- )
16
-
17
- matplotlib_windows_manager = plotter_windows_manager
@@ -1,6 +0,0 @@
1
- """A package that provides interfacing Fluent with plotters (matplotlib or pyvista)."""
2
-
3
- from ansys.fluent.visualization.plotter.plotter_objects import Plots # noqa: F401
4
- from ansys.fluent.visualization.plotter.plotter_windows_manager import ( # noqa: F401
5
- plotter_windows_manager,
6
- )
@@ -1,51 +0,0 @@
1
- """Abstract module providing plotter functionality."""
2
-
3
- from abc import ABC, abstractmethod
4
-
5
-
6
- class AbstractPlotter(ABC):
7
- """Abstract class for plotter."""
8
-
9
- @abstractmethod
10
- def plot(self, data: dict) -> None:
11
- """Draw plot in window.
12
-
13
- Parameters
14
- ----------
15
- data : dict
16
- Data to plot. Data consists the list of x and y
17
- values for each curve.
18
- """
19
- pass
20
-
21
- @abstractmethod
22
- def close(self):
23
- """Close plotter window."""
24
- pass
25
-
26
- @abstractmethod
27
- def is_closed(self):
28
- """Check if the plotter window is closed."""
29
- pass
30
-
31
- @abstractmethod
32
- def save_graphic(self, file_name: str):
33
- """Save graphics to the specified file.
34
-
35
- Parameters
36
- ----------
37
- file_name : str
38
- File name to save graphic.
39
- """
40
- pass
41
-
42
- @abstractmethod
43
- def set_properties(self, properties: dict):
44
- """Set plot properties.
45
-
46
- Parameters
47
- ----------
48
- properties : dict
49
- Plot properties i.e. curves, title, xlabel and ylabel.
50
- """
51
- pass
@@ -1,17 +0,0 @@
1
- """A DEPRECATED package that provides interfacing Fluent with graphics renderer."""
2
-
3
- import warnings
4
-
5
- from ansys.fluent.core.warnings import PyFluentDeprecationWarning
6
-
7
- warnings.warn(
8
- "'pyvista' is deprecated. Use 'graphics' instead.",
9
- PyFluentDeprecationWarning,
10
- )
11
-
12
- from ansys.fluent.visualization.graphics.graphics_objects import Graphics # noqa: F401
13
- from ansys.fluent.visualization.graphics.graphics_windows_manager import ( # noqa: F401
14
- graphics_windows_manager,
15
- )
16
-
17
- pyvista_windows_manager = graphics_windows_manager