-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathcloud_amount.py
More file actions
27 lines (21 loc) · 799 Bytes
/
cloud_amount.py
File metadata and controls
27 lines (21 loc) · 799 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
#------------------------------------------------------------------------------
# Platform : Cloud Amount fetching
# Project Name : SYNOP DATA DECODER
# Author : Nikhil Dhandre
# Start Date : 09-07-2016
# Last Modified : 3-07-2016
#------------------------------------------------------------------------------
import csv
def cloud_amount(x):
with open('db/cloud_amount.csv') as csvfile:
N_data=csv.reader(csvfile, delimiter=',')
code_all=[]
N_all=[]
for row in N_data:
code=row[0]
N=row[1]
code_all.append(code)
N_all.append(N)
index=code_all.index(x)
return N_all[index]
#------------------------------------------------------------------------------