Commit 6f1d89d5 authored by Jérome Perrin's avatar Jérome Perrin

fixup! change in runKnowledge extraction method

parent d14ade8e
...@@ -185,14 +185,9 @@ def _runKnowledgeExtraction(parameter_dict): ...@@ -185,14 +185,9 @@ def _runKnowledgeExtraction(parameter_dict):
data = parameter_dict #It loads the file data = parameter_dict #It loads the file
nodes = data['nodes'] nodes = data['nodes']
lista=[] for station, values in ProcessingTimes.items(): #This loop searches the elements of the Excel imported data and if these elements exist in json file append the distribution fitting results in a dictionary
for (element_id, element) in nodes.iteritems(): #This loop appends in a list the id's of the json file if station in nodes:
element['id'] = element_id parameter_dict['nodes'][station]['processingTime'] = B.ks_test(values)
lista.append(element ['id'])
for element in ProcessingTimes: #This loop searches the elements of the Excel imported data and if these elements exist in json file append the distribution fitting results in a dictionary
if element in lista:
parameter_dict['nodes'][element]['processingTime']=element
return dict(success=True, data=parameter_dict) return dict(success=True, data=parameter_dict)
except Exception, e: except Exception, e:
tb = traceback.format_exc() tb = traceback.format_exc()
......
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