> ## Documentation Index
> Fetch the complete documentation index at: https://developer.synopsys.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 04. PyRocky vs Ansys Rocky PrePost Scripting

A common question from **Ansys Rocky** users is:

**What is the difference between PyRocky and Ansys Rocky PrePost Scripting?**

The most accurate answer is that **PyRocky** should not be understood as a complete replacement for Ansys Rocky’s native automation capabilities. Instead, **PyRocky** provides a Python client layer that enables users to interact remotely with **Ansys Rocky** via the **Ansys** **Rocky PrePost Scripting**.

In other words, **PyRocky** makes **Ansys Rocky** automation more accessible from external **Python** environments while still relying on **Ansys Rocky’s** established scripting capabilities.

**Ansys Rocky PrePost Scripting** is the core **Python** based automation mechanism for creating, modifying, running, analyzing, and exporting simulation data from **Ansys Rocky** projects. It is directly connected to **Ansys Rocky’s** internal simulation objects and is especially useful for users who already understand **Ansys Rocky’s** data structure.

**PyRocky** extends this workflow by allowing users to control **Ansys Rocky** from **Python** environments outside the **Ansys Rocky** application. This makes it easier to integrate **Ansys Rocky** with the broader **Python** ecosystem and with other **PyAnsys** libraries.

A practical comparison is shown below.

| **Aspect** | **PyRocky** | **Ansys Rocky PrePost Scripting** |
| - | - | - |
| Primary purpose | Control Ansys Rocky remotely from Python | Automate Ansys Rocky model setup, simulation execution, and post-processing |
| Execution context | Used from external Python environments | Typically used from Ansys Rocky scripting environments |
| Main interface | `RockyClient` and `RockyClient.api` | Ansys Rocky PrePost scripting objects and methods |
| Level of abstraction | Python client layer over Ansys Rocky scripting capabilities | Direct access to Ansys Rocky scripting capabilities |
| Integration with Python tools | More natural integration with NumPy, Pandas, Matplotlib, Jupyter, and other Python tools | Possible, but more tied to Ansys Rocky’s scripting environment |
| Integration with PyAnsys | Designed as part of the PyAnsys ecosystem | Not the focus |
| Best suited for | Workflow automation, batch execution, remote scripting, data pipelines, and reproducible studies | Direct Ansys Rocky automation and users familiar with Ansys Rocky scripting |

Therefore, the relationship between the two is complementary.

**Ansys Rocky PrePost Scripting** provides an underlying automation capability. **PyRocky** provides a **Pythonic** access layer that makes this capability easier to use in modern automation workflows.

This distinction is important because users should not expect every **PyRocky** command to behave like a completely new high-level API. In its current form, many operations are performed through the same **Ansys** **Rocky PrePost Scripting** methods that **Ansys Rocky** users may already know.

For experienced **Ansys Rocky** users, this is an advantage: existing scripting knowledge can be transferred to **PyRocky** workflows.

For **Python** users, **PyRocky** provides a more familiar, scalable environment for building scripts, notebooks, automation tools, and engineering data pipelines.

***

* [Previous: 03. How to Get Started with PyRocky](https://developer.synopsys.com/resources/articles/03-how-get-started-pyrocky.md)
* [Next: 05. Foundation for AI-Enabled DEM Workflows](https://developer.synopsys.com/resources/articles/05-foundation-ai-enabled-dem-workflows.md)
