Question: Create a 3 * 3 tensor variable ( the initial values don't matter ) . Assign values from 1 to 9 to it and than

Create a 3*3 tensor variable (the initial values don't matter).
Assign values from 1 to 9 to it and than add 1 to each assigned value in the 3*3 tensor.
Print out the initial values and print out the new values after the assign operation.
initial = # implement initial 3x3 variable here
assign = # implement assign value here
add = # implement addition here
tf.print("Initial values:
", initial)
tf.print("New values:
", assign)
tf.print("After addition of 1:
", add)
TensorFlow code

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!