24.09., 9:00 - 11:00: Due to updates GitLab will be unavailable for some minutes between 09:00 and 11:00.

Commit 797d0d71 authored by Daniel Lehmberg's avatar Daniel Lehmberg

Merge commit '2b5659df' into configure_ci_setup

parents c289171a 2b5659df
...@@ -16,4 +16,4 @@ from suqc.parameter.postchanges import ScenarioChanges ...@@ -16,4 +16,4 @@ from suqc.parameter.postchanges import ScenarioChanges
from suqc.qoi import * from suqc.qoi import *
from suqc.request import * from suqc.request import *
__version__ = "1.0" __version__ = "1.01"
...@@ -73,7 +73,7 @@ class ParameterVariation(metaclass=abc.ABCMeta): ...@@ -73,7 +73,7 @@ class ParameterVariation(metaclass=abc.ABCMeta):
ret = dict(row) ret = dict(row)
delete_keys = list() delete_keys = list()
for k, v in ret.items(): for k, v in ret.items():
if np.isnan(v): if isinstance(v, np.float) and np.isnan(v):
delete_keys.append(k) delete_keys.append(k)
for dk in delete_keys: for dk in delete_keys:
......
...@@ -26,7 +26,7 @@ class FileDataInfo(object): ...@@ -26,7 +26,7 @@ class FileDataInfo(object):
# changes in Vadere. See also vadere issue #199 and #201. # changes in Vadere. See also vadere issue #199 and #201.
map_outputtype2index = {"IdOutputFile": 1, map_outputtype2index = {"IdOutputFile": 1,
"LogEventOutputFile": 1, "LogEventOutputFile": 1,
"NotDataKeyOutputFile": 0, "NoDataKeyOutputFile": 0,
"PedestrianIdOutputFile": 1, "PedestrianIdOutputFile": 1,
"TimestepOutputFile": 1, "TimestepOutputFile": 1,
"TimestepPedestrianIdOutputFile": 2, "TimestepPedestrianIdOutputFile": 2,
...@@ -125,9 +125,12 @@ class QuantityOfInterest(object): ...@@ -125,9 +125,12 @@ class QuantityOfInterest(object):
nr_row_indices = req_qoi.nr_row_indices nr_row_indices = req_qoi.nr_row_indices
df = pd.read_csv(filepath, delimiter=" ", header=[0], comment="#") df = pd.read_csv(filepath, delimiter=" ", header=[0], comment="#")
idx_keys = df.columns[:nr_row_indices]
return df.set_index(idx_keys.tolist()) if req_qoi.output_key.__eq__("NoDataKeyOutputFile"):
return df
else:
idx_keys = df.columns[:nr_row_indices]
return df.set_index(idx_keys.tolist())
def _add_parid2idx(self, df, par_id): def _add_parid2idx(self, df, par_id):
# from https://stackoverflow.com/questions/14744068/prepend-a-level-to-a-pandas-multiindex # from https://stackoverflow.com/questions/14744068/prepend-a-level-to-a-pandas-multiindex
......
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