pypsa.Network.consistency_check#
- Network.consistency_check(check_dtypes: bool = False, strict: Sequence | None = None) None#
Check network for consistency.
Runs a series of checks on the network to ensure that it is consistent, e.g. that all components are connected to existing buses and that no impedances are singular.
- Parameters:
check_dtypes (bool, optional) – If True, check the dtypes of the attributes in the components.
strict (list, optional) – If some checks should raise an error instead of logging a warning, pass a list of strings with the names of the checks to be strict about. If ‘all’ is passed, all checks will be strict. The default is no strict checks.
:raises ConsistencyError : If any of the checks fail and strict mode is activated.:
See also
[pypsa.consistency.check_for_unknown_buses][] : Check if buses are attached to component but are not defined in the network. [pypsa.consistency.check_for_disconnected_buses][] : Check if network has buses that are not connected to any component. [pypsa.consistency.check_for_unknown_carriers][] : Check if carriers are attached to
component but are not defined in the network.
- [pypsa.consistency.check_for_zero_impedances][]Check if component has zero
impedances. Only checks passive branch components.
- [pypsa.consistency.check_for_zero_s_nom][]Check if component has zero s_nom. Only
checks transformers.
- [pypsa.consistency.check_time_series][]Check if time series of component are
aligned with network snapshots.
- [pypsa.consistency.check_static_power_attributes][]Check static attrs p_now, s_nom,
e_nom in any component.
- [pypsa.consistency.check_time_series_power_attributes][]Check p_max_pu and
e_max_pu nan and infinite values in time series.
- [pypsa.consistency.check_assets][]Check if assets are only committable or
extendable, but not both.
- [pypsa.consistency.check_generators][]Check the consistency of generator attributes
before the simulation.
- [pypsa.consistency.check_dtypes_][]Check if the dtypes of the attributes in the
component are as expected.
- [pypsa.consistency.check_investment_periods][]Check if investment periods are aligned
with snapshots.
[pypsa.consistency.check_shapes][] : Check if shapes are aligned with related components. [pypsa.consistency.check_nans_for_component_default_attrs][] : Check for missing values
in component attributes.