This repository was archived by the owner on Mar 12, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathother_ops.py
More file actions
49 lines (45 loc) · 2.28 KB
/
other_ops.py
File metadata and controls
49 lines (45 loc) · 2.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
'''
Created on 26 Nis 2017
@author: FIRAT
'''
#agirliklarin ciktisini almak icin...
# if i == 0 or i == epoch-1:
# print(i)
# hidden1 = sess.run(z1, feed_dict = {a0: [imageY,imageA,imageS,imageI,imageYY],
# y : [classY,classA,classS,classI,classY]})
# hidden2 = sess.run(z2, feed_dict = {a0: [imageY,imageA,imageS,imageI,imageYY],
# y : [classY,classA,classS,classI,classY]})
# hidden3 = sess.run(z3, feed_dict = {a0: [imageY,imageA,imageS,imageI,imageYY],
# y : [classY,classA,classS,classI,classY]})
# output = sess.run(a3, feed_dict = {a0: [imageY,imageA,imageS,imageI,imageYY],
# y : [classY,classA,classS,classI,classY]})
# nt = sess.run(a0, feed_dict = {a0: [imageY,imageA,imageS,imageI,imageYY],
# y : [classY,classA,classS,classI,classY]})
# #
#
# np.savetxt("h1"+str(i)+".csv",hidden1,delimiter=",")
#
# np.savetxt("h2"+str(i)+".csv",hidden2,delimiter=",")
#
# np.savetxt("h3"+str(i)+".csv",hidden3,delimiter=",")
#
# np.savetxt("out"+str(i)+".csv",output,delimiter=",")
# np.savetxt("init"+str(i)+".csv",nt,delimiter=",")
#burada test kismi yapilmaktadir.
# res = sess.run(acct_res, feed_dict =
# {a0: [imageY,imageA,imageS],
# y : [classS,classY,classS]})
# mat = sess.run(acct_mat, feed_dict =
# {a0: [imageY,imageA,imageS],
# y : [classS,classY,classS]})
#
# print(res) #resolution,correctness
# print(mat) #confusion matrix
#egitim sirasinda her iterasyonda squared error hesaplamak icin -for dongusune koyulmali-
# cost = sess.run(squarredErr, feed_dict = {a0: [imageY,imageA,imageS],
# y : [classY,classA,classS]})
# cost.append(sess.run(squarredErr, feed_dict = {a0: [imageY,imageA,imageS,imageI,imageYY],
# y : [classY,classA,classS,classI,classY]}))
# print(min(cost))
# print(max(cost))
# plot(list(range(epoch)),cost,'epoch','squarred err')