From 3bc24933f4128e76ccbd6e37155ff6cccb20a182 Mon Sep 17 00:00:00 2001 From: Raghuram Subramani Date: Sat, 8 Jun 2024 18:45:09 +0530 Subject: Automate backward propagation --- src/graph.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/graph.py') diff --git a/src/graph.py b/src/graph.py index 6c8ab53..6bebb06 100644 --- a/src/graph.py +++ b/src/graph.py @@ -1,8 +1,5 @@ import tkinter as tk - from graphviz import Digraph -import matplotlib.pyplot as plt -import matplotlib.image as mpimg from .scalar import Scalar @@ -33,7 +30,7 @@ class Graph: # Create a node in the graph self.dot.node( name=uid, - label=f"{node.label} | {node.data} | grad: {node.grad}", + label=f"{node.label} | {node.data:.4f} | grad: {node.grad:.4f}", shape='record' ) -- cgit v1.2.3