Hello world in TensorFlow

#package Import
import
tensorflow as tensorF

hello = tensorF.constant("Hello")

world = tensorF.constant(" World!")

We begin by importing the TensorFlow package and loading the string:

helloworld=hello+world

with tensorF.Session() as sess:
answer = sess.run(helloworld)
print (answer)

The preceding code is the most basic form of TensorFlow code that we will be writing. Later in this chapter, we will be dealing with examples that we looked at in the previous chapter.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset