Skip to main content

Keras inspired pure python neural network library

Project description

txnet

Keras inspired pure python neural network library

from txnet.models import Sequential
from txnet.layers import Dense, ReLU, Sigmoid

import numpy as np
x = np.array([
  [1, 1],
  [0, 1],
  [1, 0],
  [0, 0]
])

y = np.array([[0], [1], [1], [0]])

model = Sequential()
model.add(Dense(2, 5, 0.01))
model.add(ReLU())
model.add(Dense(5, 1, 0.01))
model.add(Sigmoid())

model.fit(x, y, 10000)

print(model.predict(x))

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

txnet-0.1.tar.gz (1.9 kB view hashes)

Uploaded Source

Built Distribution

txnet-0.1-py3-none-any.whl (2.5 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page