Basic data types
igraph_ctypes.types module
AttributeCombinationSpecification = Mapping[str | None, AttributeCombinationSpecificationEntry] | AttributeCombinationSpecificationEntry
module-attribute
Type alias for mappings that specify how to merge vertex or edge attributes during an operation that contracts multiple vertices or edge into a single one.
None specifies the default behaviour.
AttributeCombinationSpecificationEntry = Literal['default', 'ignore', 'sum', 'prod', 'min', 'max', 'random', 'first', 'last', 'mean', 'median', 'concat'] | Callable[[Sequence[Any]], Any]
module-attribute
Type alias for values that can be accepted in an AttributeCombinationSpecification_ mapping.
BoolArray = npt.NDArray[np_type_of_igraph_bool_t]
module-attribute
Type alias for NumPy arrays containing igraph booleans
EdgeLike = int
module-attribute
Type alias for Python types that can be converted to an igraph edge ID
EdgeSelector = Iterable[EdgeLike] | Literal['all'] | EdgeLike | None
module-attribute
Type alias for Python types that can be converted to an igraph edge selector.
FileLike = int | bytes | str | PathLike[bytes] | PathLike[str] | IOBase
module-attribute
Type alias for Python types that can be used in places where the C core expects a FILE* pointer.
IntArray = npt.NDArray[np_type_of_igraph_int_t]
module-attribute
Type alias for NumPy arrays containing igraph integers
RealArray = npt.NDArray[np_type_of_igraph_real_t]
module-attribute
Type alias for NumPy arrays containing igraph reals
VertexLike = int
module-attribute
Type alias for Python types that can be converted to an igraph vertex ID
VertexPair = tuple[VertexLike, VertexLike]
module-attribute
A pair of objects that can both be converted into igraph vertex IDs
VertexSelector = Iterable[VertexLike] | Literal['all'] | VertexLike | None
module-attribute
Type alias for Python types that can be converted to an igraph vertex selector.