-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathCompareFiles.py
More file actions
44 lines (38 loc) · 762 Bytes
/
CompareFiles.py
File metadata and controls
44 lines (38 loc) · 762 Bytes
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
import os
a=[]
b=[]
i=0
k=0
currentimg = '"test10.png"'
f= open("groundTruth.csv","r+")
y = f.readline()
while y is not '':
y=f.readline()
x=y.split(',')
print(x)
if currentimg == x[0]:
a.append([x[0],float(x[1])+float(x[3]),float(x[2])+float(x[4]),x[5]])
else:
b.append(a)
a=[]
currentimg=x[0]
k+=1
#print(b)
a=[]
c=[]
i=0
k=0
currentimg = '"test10.png"'
f= open("evaluate-export302.csv","r+")
y=f.readline()
while y is not '':
y=f.readline()
x=y.split(',')
if currentimg == x[0]:
a.append([x[0],float(x[1])+float(x[3]),float(x[2])+float(x[4]),x[5]])
else:
c.append(a)
a=[]
currentimg=x[0]
k+=1
new_file = "evaluate-export1501.csv"