Commit bce09be9 authored by Bognár, Á.'s avatar Bognár, Á.
Browse files

give unique name for the sensopr points based on row/column within the module

parent fad729bc
......@@ -10,18 +10,8 @@ def ill_to_df(p_name):
surfnames = list(pts['surf_name']) # read the surf names fom the csv
# make a list of unique names for the ptss. These will be the col names for the ill dataframe
ptsnames = []
n = 0
for i in list(range(len(surfnames))):
if surfnames[i-1] != surfnames[i]:
n=0
ptsnames.append(surfnames[i] + '_{}'.format(str(n)))
n = n+1
ptsnames = []
for i in list(range(len(surfnames))):
ptsnames.append(surfnames[i] + 'c{}r{}'.format(pts['ci'][i], )
ptsnames.append(surfnames[i] + 'c{}r{}'.format(pts.loc[i, 'ci'], pts.loc[i, 'ri']))
ill = pd.read_csv(r'res\{}.ill'.format(p_name), sep=' ', skipinitialspace=True, header=None, dtype=np.float64)
# converting fraction hours seems complicated because of rounding errors, so for now, lazily we generate our own timestamps from the first two rows
timestepmins = pd.Timedelta(minutes=int(round((ill[2][1] - ill[2][0]) * 60)))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment