Skip to content

Commit 7880ed8

Browse files
authored
Merge pull request #202 from Abioy/master
Improve `DataTypeError` message with `parametrized dimension`
2 parents acfb490 + cd2f982 commit 7880ed8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

wonnx/src/utils.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -487,10 +487,11 @@ impl ValueInfoProto {
487487
.get_shape()
488488
.get_dim()
489489
.iter()
490-
.map(|x| {
490+
.enumerate()
491+
.map(|(idx, x)| {
491492
if x.has_dim_param() {
492493
return Err(DataTypeError::ParametrizedDimensionUnsupported(
493-
x.get_dim_param().to_string(),
494+
self.get_name().to_string() + "#" + &idx.to_string(),
494495
));
495496
}
496497
Ok(x.get_dim_value())

0 commit comments

Comments
 (0)