Skip to content

Commit 35cbe83

Browse files
rscarrera27kkweon
authored andcommitted
change name of W_val and cost_val (hunkim#99)
* Change Variable name of W_val and cost_val W_val and cost_val to W_history and cost_history To understand the purpose of variables easily * Revert "Change Variable name of W_val and cost_val" This reverts commit d75f37f. * Change Variable name of W_val and cost_val W_val and cost_val to W_record and cost_record To understand the purpose of variables easily * Change name of W_val and cost_val W_val and cost_val to W_record and cost_record To understand the purpose of variables easily hunkim#99 wasn't refactored by mistake * Change W_val cost_val W_val and cost_val to W_history and cost_history To understand the purpose of variables easily
1 parent db3c3a5 commit 35cbe83

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

lab-03-1-minimizing_cost_show_graph.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@
2020
sess.run(tf.global_variables_initializer())
2121

2222
# Variables for plotting cost function
23-
W_vals = []
24-
cost_vals = []
23+
W_history = []
24+
cost_history = []
2525

2626
for i in range(-30, 50):
2727
curr_W = i * 0.1
2828
curr_cost = sess.run(cost, feed_dict={W: curr_W})
29-
W_vals.append(curr_W)
30-
cost_vals.append(curr_cost)
29+
W_history.append(curr_W)
30+
cost_history.append(curr_cost)
3131

3232
# Show the cost function
33-
plt.plot(W_vals, cost_vals)
33+
plt.plot(W_history, cost_history)
3434
plt.show()

0 commit comments

Comments
 (0)