Skip to content

Commit

Permalink
Merge pull request #884 from PowerGridModel/feature/improve-documenta…
Browse files Browse the repository at this point in the history
…ton-on-batch-error

improve docs on batch error
  • Loading branch information
TonyXiang8787 authored Jan 28, 2025
2 parents fda8c26 + 51c42bf commit 01bd0a4
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions src/power_grid_model/_core/power_grid_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@ class PowerGridModel:
@property
def batch_error(self) -> PowerGridBatchError | None:
"""
Get the batch error object, if present
Get the batch error object, if present, after a batch calculation with errors.
Also works when continue_on_batch_error was set to True during the calculation.
Returns:
Batch error object, or None
Expand Down Expand Up @@ -474,8 +476,9 @@ def calculate_power_flow(
- None: Row based data for the specified component types.
- ComponentAttributeFilterOptions: Columnar data for the specified component types.
- set[str] | list[str]: Columnar data for the specified component types and attributes.
continue_on_batch_error (bool, optional): Continue the program (instead of throwing error) if some
scenarios fail.
continue_on_batch_error (bool, optional):
Continue the program (instead of throwing error) if some scenarios fail.
You can still retrieve the errors and succeeded/failed scenarios via the batch_error.
decode_error (bool, optional):
Decode error messages to their derived types if possible.
Expand Down Expand Up @@ -568,8 +571,9 @@ def calculate_state_estimation(
- None: Row based data for the specified component types.
- ComponentAttributeFilterOptions: Columnar data for the specified component types.
- set[str] | list[str]: Columnar data for the specified component types and attributes.
continue_on_batch_error (bool, optional): Continue the program (instead of throwing error) if some
scenarios fail.
continue_on_batch_error (bool, optional):
Continue the program (instead of throwing error) if some scenarios fail.
You can still retrieve the errors and succeeded/failed scenarios via the batch_error.
decode_error (bool, optional):
Decode error messages to their derived types if possible.
Expand Down Expand Up @@ -653,6 +657,7 @@ def calculate_short_circuit(
- set[str] | list[str]: Columnar data for the specified component types and attributes.
continue_on_batch_error (bool, optional):
Continue the program (instead of throwing error) if some scenarios fail.
You can still retrieve the errors and succeeded/failed scenarios via the batch_error.
decode_error (bool, optional):
Decode error messages to their derived types if possible.
short_circuit_voltage_scaling ({ShortCircuitVoltageSaling, str}, optional):
Expand Down

0 comments on commit 01bd0a4

Please sign in to comment.