Beispiel #1
0
def collect_papers(id_list):
    count = 0
    for ar_id in id_list:
        r = requests.get('http://arxiv.org/e-print/' + ar_id)
        count += 1

        f_name = os.getcwd() + "/uploads/" + ar_id

        with open(f_name, "wb") as code:
            code.write(r.content)

        print("Update called for", f_name)
        sys_update.graph_update(ar_id)
Beispiel #2
0
def collect_papers(id_list):
    data = {}
    datum = {}
    count = 0
    for ar_id in id_list:

        r = requests.get('http://arxiv.org/e-print/' + ar_id)
        count += 1

        f_name = os.getcwd() + "/uploads/" + ar_id

        with open(f_name, "wb") as code:
            code.write(r.content)

        datum = sys_update.graph_update(ar_id)
        if datum:
            data[count - 1] = datum
    return data