项目作者: MrRobb

项目描述 :
An statistical approach to neural networks
高级语言: Python
项目地址: git://github.com/MrRobb/PE-B7.git
创建时间: 2017-12-27T17:58:19Z
项目社区:https://github.com/MrRobb/PE-B7

开源协议:

下载


Neural Networks

Introducción

An statistical approach to neural networks

Instalar requerimientos (macOS)

Ejecuta en la terminal:

  1. /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  2. brew install python
  3. brew postinstall python
  4. brew install python3
  5. brew postinstall python3
  6. sudo easy_install pip
  7. sudo pip install tensorflow
  8. sudo pip3 install tensorflow

Instalar requerimientos (Ubuntu)

Ejecuta en la terminal:

  1. sudo apt-get update
  2. sudo apt-get upgrade
  3. sudo apt-get install python2.7
  4. sudo apt-get install python3
  5. sudo apt-get install python-pip
  6. sudo apt-get install python3-pip

Instalar requerimientos (Windows)

Baja al final de la —-> página <—- e instala python3 (Windows Executable Installer)

Ejecuta en la terminal:

  1. pip3 install --upgrade tensorflow
  2. pip3 install --upgrade tensorflow-gpu

Para ver si funciona ejecuta:

  1. python

Y en la consola interactiva escribe:

  1. >>> import tensorflow as tf
  2. >>> hello = tf.constant('Hello, TensorFlow!')
  3. >>> sess = tf.Session()
  4. >>> print(sess.run(hello))

Asegurate de que sale (significaría que todo funciona correctamente):

  1. Hello, TensorFlow!

Cómo ejecutar

Ahora podéis ejecutar los códigos del archivo 1layer.py sin problema, así:

  1. python 1layer.py 2> /dev/null

Cómo hacer un timing

Si queréis saber cuánto tarda vuestro ordenador en ejecutar el código, tan solo ejecuta:

  1. time python 1layer.py > /dev/null 2> /dev/null

1 layer —> 39.804 total, 39.112 total, 40.261 total, 39.854 total

31,629 total (1), 31,645 total (1),

3 layer —> 206.42 total, 189.27 total, 189.98 total, 190.19 total (4 ejecuciones)

180,64 total (3), 177.55 total (3)

5 layer —> 436.96 total, 412.55 total, 486.97 total (5), 508.82 total (5)

432.21 total (5), 492.19 total (5)