bqskit.utils.typing

This module implements many helper functions to check types.

Functions

is_bool(x)

Return true if x is a boolean value.

is_complex(x)

Return true if x is complex.

is_hermitian(H[, tol])

Return true if H is a hermitian matrix.

is_integer(x)

Return true if x is an integer.

is_iterable(x)

Return true if x is an iterable object.

is_mapping(x)

Return true if x is a mapping.

is_matrix(M)

Return true if M is a matrix.

is_numeric(x)

Return true if x is numeric.

is_real_number(x)

Return true if x is a real number.

is_sequence(x)

Return true if x is a sequence.

is_sequence_of_int(x)

Return true if x is a sequence of integers.

is_sized(x)

Return true if x is a sized object.

is_skew_hermitian(H[, tol])

Return true if H is a skew hermitian matrix.

is_square_matrix(M)

Return true if M is a square matrix.

is_valid_radixes(radixes[, num_qudits])

Determine if the sequence of radixes is valid.

is_vector(V)

Return true if V is a vector.