modeci_mdf.interfaces.onnx.importer.get_shape_params

modeci_mdf.interfaces.onnx.importer.get_shape_params(shape: TensorShapeProto) Tuple[source]

Small helper function to extract a tuple from the TensorShapeProto. These objects can contain both integer dimensions and parameter dimensions that are variable, like ‘batch_size’.

Parameters:

shape – The ONNX shape proto to process.

Returns:

A tuple that can contain both integers and strings for parameter dimensions.