Commit d00a9d23 authored by Benoit Favre's avatar Benoit Favre
Browse files

update bibliovid scrapper fields

parent 0907e22c
......@@ -24,19 +24,34 @@ for article in articles['results']:
return node.get_text().strip()
return ''
#title = safe_text(main.find('h1'))
#link = divs[8].find('a').attrs['href']
#findings = safe_text(divs[12].find('div'))
#take_away = safe_text(divs[14].contents[0].find('div'))
#relevance_level = safe_text(divs[16].contents[0].find('div'))
#objectives = safe_text(divs[18].contents[0].find('div'))
#methods = safe_text(divs[20].contents[0].find('div'))
#article['link'] = link
#article['findings'] = findings
#article['take_away'] = take_away
#article['relevance_level'] = relevance_level
#article['objectives'] = objectives
#article['methods'] = methods
title = safe_text(main.find('h1'))
link = divs[8].find('a').attrs['href']
findings = safe_text(divs[12].find('div'))
take_away = safe_text(divs[14].contents[0].find('div'))
relevance_level = safe_text(divs[16].contents[0].find('div'))
objectives = safe_text(divs[18].contents[0].find('div'))
methods = safe_text(divs[20].contents[0].find('div'))
findings = safe_text(divs[14].find('div'))
take_away = safe_text(divs[16].contents[0].find('div'))
relevance_level = safe_text(divs[18].contents[0].find('div'))
objectives = safe_text(divs[20].contents[0].find('div'))
methods = safe_text(divs[22].contents[0].find('div'))
article['link'] = link
article['findings'] = findings
article['take_away'] = take_away
article['relevance_level'] = relevance_level
article['objectives'] = objectives
article['results'] = findings
article['synthesis'] = take_away
article['strength_of_evidence_details'] = relevance_level
article['goals'] = objectives
article['methods'] = methods
print(json.dumps(articles, indent=2))
......
Supports Markdown
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