The Prediction module is in charge of running the SimAI-powered predictions on the geometries that you have uploaded.

A prediction represents a numerical prediction with geometry and boundary conditions. The arguments to the method depend on your model.

# Run a prediction on a given geometry with the specified velocity.
velocity = 10.0
prediction = geometry.run_prediction(Vx=velocity)


class PredictionDirectory#

Provides a collection of methods related to model predictions.

This method is accessed through client.prediction.


import ansys.simai.core

simai = ansys.simai.core.from_config()
delete(prediction: Prediction | str) None#

Delete a specific prediction from the server.


prediction (Prediction | str) – ID or model of the prediction.


ansys.simai.core.errors.NotFoundError – No prediction with the given ID exists.

get(id: str) Prediction#

Get a specific prediction object from the server by ID.


id (str) – ID of the prediction.


Prediction instance with the given ID if it exists.


NotFoundError – No prediction with the given ID exists.

Return type:


list(workspace: Workspace | str | None = None) List[Prediction]#

List all predictions on the server that belong to the specified workspace or the configured one.


workspace (Workspace | str | None) – ID or model of the workspace to list the predictions for. This parameter is necessary if no workspace is set for the client.

run(geometry: Geometry | str, boundary_conditions: Dict[str, Number] | None = None, **kwargs) Prediction#

Run a prediction on a given geometry with a given boundary conditions.

Boundary conditions can be passed as a dictionary or as kwargs.

To learn more about the expected boundary conditions in your workspace, you can use the simai.current_workspace.model.boundary_conditions or simai.predictions.boundary_conditions method, where ex is your ~ansys.simai.core.client.SimAIClient object.

  • geometry (Geometry | str) – ID or model of the target geometry.

  • boundary_conditions (Dict[str, Number] | None) – Boundary conditions to apply in dictionary form.


Created prediction object.


ProcessingError – If the server failed to process the request.

Return type:



simai = ansys.simai.core.from_config()
geometry = simai.geometries.list()[0]
prediction =, dict(Vx=10.5, Vy=2))

Using kwargs:

prediction =, Vx=10.5, Vy=2)
property boundary_conditions: Dict[str, Any]#

Information on the boundary conditions expected by the model of the current workspace. For example, the prediction’s input.

property info#

Information on the prediction’s inputs and outputs.


from pprint import pprint
import ansys.simai.core

simai = ansys.simai.core.from_config()
prediction_info =
property physical_quantities: Dict[str, Any]#

Information on the physical quantities generated by the model. For example, the prediction’s output.


class Prediction#

Provides the local representation of a prediction object.

delete() None#

Remove a prediction from the server.

reload() None#

Refresh the object with its representation from the server.

wait(timeout: float | None = None) bool#

Wait for all jobs concerning the object to either finish or fail.


timeout (float | None) – Maximum amount of time in seconds to wait. The default is None, in means that there is no maximum on the time to wait.


True if the computation has finished, False if the operation timed out.

Return type:


property boundary_conditions: Dict[str, Number]#

Boundary conditions of the prediction.

property confidence_score: str#

Confidence score, which is either high or low.

This method blocks until the confidence score is computed.

property failure_reason#

Optional message giving the causes for why the creation of the object failed.

See also

property fields: dict#

Dictionary containing the raw object representation.

property geometry: Geometry#

Parent geometry.

The parent geometry is queried if is not already known by the current SimAI client session.

See also

  • geometry_id: Get the parent geometry’s ID without query.

property geometry_id: str#

ID of the parent geometry.

See also

property has_failed#

Boolean indicating if the creation of the object failed.

property id: str#

ID of the object on the server.

property is_pending#

Boolean indicating if the object is still in creation. The value becomes False once object creation is either successful or has failed.

property is_ready#

Boolean indicating if the object has finished creating without error.

property post: PredictionPostProcessings#

Namespace containing methods for postprocessing the result of a prediction.

For more information, see the PredictionPostProcessings class.