Skip to content

Commit 19eabc4

Browse files
committed
Missing ToString
1 parent 00a647c commit 19eabc4

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

src/ConvNetSharp.Flow/Ops/Reshape.cs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,5 +90,14 @@ public override Dictionary<string, object> GetData()
9090

9191
return data;
9292
}
93+
94+
public override string ToString()
95+
{
96+
if (this.Parents[0] is Reshape<T>)
97+
{
98+
return this.Parents[0].ToString();
99+
}
100+
return $"reshape({this.Parents[0]})";
101+
}
93102
}
94103
}

src/ConvNetSharp.Flow/Ops/Shape.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,5 +48,10 @@ public override Volume<T> Evaluate(Session<T> session)
4848

4949
return this.Result;
5050
}
51+
52+
public override string ToString()
53+
{
54+
return $"shape({this.Parents[0]})";
55+
}
5156
}
5257
}

0 commit comments

Comments
 (0)