Getting Started with Python Deep Learning Framework TensorFlow (2)

Author: Zen and the Art of Computer Programming

1 Introduction

1.1 Why write this article?

Although TensorFlow is already one of the most popular deep learning frameworks, many junior developers do not understand some basic concepts and terms of the framework, nor do they have a systematic grasp of how to build a simple neural network model, so this article is written It can help readers quickly get started with TensorFlow and master these basic knowledge, so as to deepen their understanding of TensorFlow.

1.2 Main content of this article

This article will be divided into the following parts:

  • TensorFlow installation and environment configuration
  • Data structures (tensors), computation graphs and sessions in TensorFlow
  • Neural Network Implementation Using ReLU Activation Function
  • Applying the MNIST dataset to a neural network to recognize handwritten digits
  • Build complex neural network models and train

2. TensorFlow installation and environment configuration

2.1 Install TensorFlow

2.2 Configure environment variables

If you have installed multiple versions of software such as Python or Anaconda on your computer, you may need to configure environment variables to call TensorFlow correctly. Enter the following command in a terminal or command prompt to set the environment variable:

export PATH=$PATH:/path/to/your/tensorflow/installation/bin # 指向TensorFlow的安装路径

2.3 Verify that the installation was successful

Open the Python terminal and enter the following command to test whether TensorFlow is installed successfully:

Guess you like

Origin blog.csdn.net/universsky2015/article/details/132222896