From 4c094699ee6729e5397484ab8dff4335fa817565 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20C=C3=A9r=C3=A8s?= Date: Tue, 26 Nov 2019 01:19:36 -0500 Subject: [PATCH] alignement: renomage des nom des fonctions --- data/wikimedica/alignement.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/data/wikimedica/alignement.py b/data/wikimedica/alignement.py index cb807df..231acca 100644 --- a/data/wikimedica/alignement.py +++ b/data/wikimedica/alignement.py @@ -15,7 +15,7 @@ USER_AGENT = "WikimedicaDiseaseSearch/0.1 (https://gitlab.com/matteodelabre/wiki session = requests.Session() session.headers = {'User-Agent': USER_AGENT} -def make_sparql_request_wikimedica(page, request): +def request_wikimedica(page, request): """ Effectue une requête SPARQL sur une page de WikiMedica @@ -31,7 +31,7 @@ def make_sparql_request_wikimedica(page, request): return [row.asdict() for row in qres] -def make_sparql_request_endpoint(endpoint, request): +def request_endpoint(endpoint, request): """ Effectue une requête SPARQL sur point d'accés @@ -60,7 +60,7 @@ request_name_uri = """ } """ -entitys_dic = make_sparql_request_wikimedica( +entitys_dic = request_wikimedica( SIGNES_ET_SYMPTOMES_WIKIMEDICA_PAGE, request_name_uri ) @@ -83,7 +83,7 @@ for entity in entitys_dic: }} """.format(PREFIX_PROPERTY) - prop_Wikidata_id = make_sparql_request_wikimedica( + prop_Wikidata_id = request_wikimedica( entity['uri'], request_prop_Wikidata_id ) @@ -108,7 +108,7 @@ for entity in entitys_dic: }} """.format((entity['name']).lower(), (entity['name']).capitalize()) - list_wikidata_pages_uri = (make_sparql_request_endpoint( + list_wikidata_pages_uri = (request_endpoint( WIKIDATA_SPARQL_ENDPOINT, request_search_by_name ))['results']['bindings']