Skip to main content

Deep Learning for Simple Folk. Built on Keras

Project description

Deep Learning for Simple Folk

Built in Python on Keras.

CircleCI codecov Documentation Status PyPI version

Read the documentation at conx.readthedocs.io

Implements Deep Learning neural network algorithms using a simple interface with easy visualizations and useful analytical. Built on top of Keras, which can use either TensorFlow, Theano, or CNTK.

The network is specified to the constructor by providing sizes. For example, Network(“XOR”, 2, 5, 1) specifies a network named “XOR” with a 2-node input layer, 5-unit hidden layer, and a 1-unit output layer.

Example

Computing XOR via a target function:

from conx import Network, SGD

dataset = [[[0, 0], [0]],
          [[0, 1], [1]],
          [[1, 0], [1]],
          [[1, 1], [0]]]

net = Network("XOR", 2, 5, 1, activation="sigmoid")
net.set_dataset(dataset)
net.compile(loss='mean_squared_error',
            optimizer=SGD(lr=0.3, momentum=0.9))
net.train(2000, report_rate=10, accuracy=1)
net.test()

Install

pip install conx -U

You will need to decide whether to use Theano, TensorFlow, or CNTK. Pick one. See docs.microsoft.com for installing CNTK on Windows or Linux. All platforms can also install either of the others using pip:

pip install theano

or

pip install tensorflow

Note: you may need to use pip3, or admin privileges (eg, sudo), or a user environment.

To use a Keras backend other than TensorFlow, edit (or create) ~/.keras/kerson.json, like:

{
    "backend": "theano",
    "image_data_format": "channels_last",
    "epsilon": 1e-07,
    "floatx": "float32"
}

Examples

See the notebooks folder and the documentation for additional examples.

Project details


Download files

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

Source Distribution

conx-3.1.0.tar.gz (33.3 kB view details)

Uploaded Source

Built Distribution

conx-3.1.0-py2.py3-none-any.whl (38.9 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file conx-3.1.0.tar.gz.

File metadata

  • Download URL: conx-3.1.0.tar.gz
  • Upload date:
  • Size: 33.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for conx-3.1.0.tar.gz
Algorithm Hash digest
SHA256 d995f01b612dc88a9b4e599d11d4532e66cd2f8b9665fedfa530eef14a709ad9
MD5 8196b1ea88a05d0c8b43f7a5e7f85b4d
BLAKE2b-256 6ac6bf54d02d552a7bdcc927ac3ef17e092ad56466b74cce4394be23b1a15696

See more details on using hashes here.

File details

Details for the file conx-3.1.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for conx-3.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 8e79de0603962d5cbfb8bf48aa46e851a255785e0ed2cbe29091c3e56cd4e30c
MD5 e70d6e9bbe6fc727b771ab8c2e03add8
BLAKE2b-256 77eba68c5d191d569ed8e434b8cf683964a06375d5139558d16c360d458ed3b9

See more details on using hashes here.

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