ExTorch.Utils.Types (extorch v0.1.0-pre0)
General type hierarchy comparison utils
Link to this section Summary
Functions
Given a list/tuples with elements or lists/tuples of elements, determine the base type
ExTorch.DType.base_type()
that the list should have when converting it into a tensor.
Given two basic types, compare them and return the type that subsumes the other one.
Link to this section Functions
Link to this function
collect_types(tup, acc)
Given a list/tuples with elements or lists/tuples of elements, determine the base type
ExTorch.DType.base_type()
that the list should have when converting it into a tensor.
Link to this function
compare_types(x, y)
@spec compare_types(ExTorch.DType.base_type(), ExTorch.DType.base_type()) :: ExTorch.DType.base_type()
Given two basic types, compare them and return the type that subsumes the other one.