Commit cc8f7ab6 authored by Achim Klaus Völker's avatar Achim Klaus Völker
Browse files

fixed split for linux systems

parent 426c3f16
......@@ -382,13 +382,13 @@ def read_timeseries_matpower(input_mat, mapping_conf):
data = loadmat(input_mat, struct_as_record=True)
rootname, extension = splitext(input_mat)
if os.name == 'nt':
rootname = rootname.split("\\")[-1]
else:
rootname = rootname.split("/")[-1]
else:
rootname = rootname.rsplit('/', 1)[-1]
busses = data[rootname]['bus'][0][0]
if len(busses) != len(map):
print ("numbers of busses in mapping differs from number of busses in .mat")
return
......
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