{"action":"opened","issue":{"url":"https://api.github.com/repos/codeforscience/sciencefair/issues/4","repository_url":"https://api.github.com/repos/codeforscience/sciencefair","labels_url":"https://api.github.com/repos/codeforscience/sciencefair/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/codeforscience/sciencefair/issues/4/comments","events_url":"https://api.github.com/repos/codeforscience/sciencefair/issues/4/events","html_url":"https://github.com/codeforscience/sciencefair/issues/4","id":136971237,"number":4,"title":"Linking figures (with thumbnails) to papers","user":{"login":"Blahah","id":836040,"avatar_url":"https://avatars.githubusercontent.com/u/836040?v=3","gravatar_id":"","url":"https://api.github.com/users/Blahah","html_url":"https://github.com/Blahah","followers_url":"https://api.github.com/users/Blahah/followers","following_url":"https://api.github.com/users/Blahah/following{/other_user}","gists_url":"https://api.github.com/users/Blahah/gists{/gist_id}","starred_url":"https://api.github.com/users/Blahah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Blahah/subscriptions","organizations_url":"https://api.github.com/users/Blahah/orgs","repos_url":"https://api.github.com/users/Blahah/repos","events_url":"https://api.github.com/users/Blahah/events{/privacy}","received_events_url":"https://api.github.com/users/Blahah/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-02-27T21:37:40Z","updated_at":"2016-02-27T21:37:40Z","closed_at":null,"body":"@freeman-lab's [pdf-to-png](https://github.com/freeman-lab/pdf-to-png) will be used to create paper thumbnails. It would be cool to associate individual figures with each paper, and provide thumbnails that can be followed to the full-size images.\r\n\r\nI solved a good chunk of this problem for a related project, but the solution only works for articles in EuropePMC: [open_access_figures](https://github.com/slidewinder/open_access_figures/).\r\n\r\nThe  `getfigures` script there runs [getpapers](https://github.com/ContentMine/getpapers) with a user-specified query to download the XML and figure images (where available) for all papers matching the query in EuropPMC. It then parses the XML to identify the figures and extract the captions, and it also generates URLs linking to the thumbnails on EuropePMC (which are predictable once you have the full image filenames).\r\n\r\nSo, I think the initial goal should be to generate the following:\r\n\r\n- a dataset containing all the figures from EuropePMC\r\n- another with the thumbnails for those figures\r\n- metadata for each article - an array of figures with:\r\n  - caption\r\n  - thumbnail (url / checksum)\r\n  - full figure image (url / checksum)\r\n\r\nHere's how to achieve that:\r\n\r\n- the captions can be generated using the EuropePMC fulltext dumps here: \r\n- the full figures can be pulled using getpapers (or the EuropePMC api directly)\r\n- the thumbnails can be scraped once the full images are pulled, the same way as in the `getfigures` script linked above.\r\n\r\nHelp and ideas very welcome. I'm happy to do this myself, but won't get to it for at least a few days, possibly longer."}}