Skip to content

Tiny automatic differentiation (autodiff) engine for NumPy tensors implemented in Python.

Notifications You must be signed in to change notification settings

theolepage/tensorflood

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

TensorFlood

Tiny automatic differentiation (autodiff) engine implemented in Python.

The following resources were used while creating this project:

Example

The notebook examples/classification.ipynb demonstrates how to use the engine and how it can be used to train a small neural network.

Usage

from tensorflood.engine import Graph, Variable, Constant

with Graph() as g:
    x = Variable(2, name='x')
    y = Variable(10, name='y')
    c = Constant(7, name='c')
    
    z = (x * y) + c
    # z.data = 27
    
    z.backward()
    # x.grad = 10 (dz/dx)
    # y.grad = 2  (dz/dy)
    # c.grad = 1  (dz/dc)

To-Do

  • NN: Adam optimizer, more layers
  • Merge backward_ and backward
  • Refactor hasattr(node, 'input_nodes')
  • Unit tests with pytorch

About

Tiny automatic differentiation (autodiff) engine for NumPy tensors implemented in Python.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages