qrunch.quantum.backends.backends_utils

Utility functions for backend operations.

Functions

convert_circuits_to_error_log(circuits)

Convert a list of UniversalGateCircuit objects to an error log and return it.

has_internet_connection()

Check if there is an active internet connection.

toggle_global_type_checking(*, enable)

Turn off the internet connection check.

convert_circuits_to_error_log(circuits: Sequence[UniversalGateCircuit]) str

Convert a list of UniversalGateCircuit objects to an error log and return it.

Parameters:

circuits (Sequence[UniversalGateCircuit]) – List of UniversalGateCircuit objects to save.

Return type:

str

has_internet_connection() bool

Check if there is an active internet connection.

Returns:

True if there is an active internet connection, False otherwise.

Return type:

bool

toggle_global_type_checking(*, enable: bool) None

Turn off the internet connection check.

This is useful for testing purposes.

Parameters:

enable (bool)

Return type:

None