def ExtraContext(start, end, pData, token_key): # Lijstje maken met alle patientdata UIDs overlaps = {} externals = getExternal(start, end, token_key) for e in externals: overlaps[e] = getAllDirectlyConnectedConcepts(e, token_key) # Measeure overlap for each candidate result = [] return result
def contextualEnrichment(start, end, pData, token_key): print start print end out = {} if end == "all": for s in start: out[s] = getAllDirectlyConnectedConcepts(s, token_key) else: for s in start: out[s] = getExternal(s, end, token_key) return out