Skip to content

Instantly share code, notes, and snippets.

@kaplun
kaplun / snippet_of_marc.xml
Created July 7, 2016 12:01
snippet of marcxml for Mihai
<record><datafield tag="700" ind1=" " ind2=" "><subfield code="a">Ciao</subfield></datafield><datafield tag="700" ind1=" " ind2=" "><subfield code="a">Mihai</subfield><subfield code="a">Mihai</subfield></datafield><datafield tag="700" ind1=" " ind2=" "><subfield code="a">Bivol</subfield></datafield><datafield tag="100" ind1=" " ind2=" "><subfield code="a">Sam</subfield></datafield></record>
@kaplun
kaplun / 462477.json
Created August 16, 2016 08:03
Example of impact graph response from inspirehep
{
"inspire_id": "462477",
"title": "Maps of dust IR emission for use in estimation of reddening and CMBR foregrounds",
"citations": [
{
"inspire_id": "1385065",
"title": "The Light Curve of the Macronova Associated With the Long\u2013short Burst GRB 060614",
"citation_count": 0,
"year": "2015"
},
#!/usr/bin/env python
import requests
import csv
import time
import click
import shelve
from urllib import quote
ERROR: duplicate usage of INSPIRE:INSPIRE-00573420: http://inspirehep.net/record/1052142 (ORIGINAL_BAI:J.J.Salzer.1, recid:1052142, INSPIRE:INSPIRE-00573420, BAI:J.J.SALZER.1) Vs. http://inspirehep.net/record/1259206 (recid:1259206, INSPIRE:INSPIRE-00573420)
ERROR: duplicate usage of INSPIRE:INSPIRE-00572633: http://inspirehep.net/record/1274531 (ORIGINAL_BAI:Fang.Ye.1, ORCID:0000-0001-5285-9931, recid:1274531, INSPIRE:INSPIRE-00572633, BAI:FANG.YE.1) Vs. http://inspirehep.net/record/1484772 (CERN:CERN-773282, recid:1484772, INSPIRE:INSPIRE-00572633)
ERROR: duplicate usage of INSPIRE:INSPIRE-00572641: http://inspirehep.net/record/1273411 (ORIGINAL_BAI:C.Gnendiger.1, recid:1273411, INSPIRE:INSPIRE-00572641, BAI:C.GNENDIGER.1) Vs. http://inspirehep.net/record/1484774 (CERN:CERN-806189, recid:1484774, INSPIRE:INSPIRE-00572641)
ERROR: duplicate usage of INSPIRE:INSPIRE-00573430: http://inspirehep.net/record/1279254 (ORIGINAL_BAI:D.A.Takahashi.1, recid:1279254, INSPIRE:INSPIRE-00573430, BAI:D.A.TAKAHASHI.1) Vs. ht
@kaplun
kaplun / merged_records.xml
Created September 27, 2016 11:37
Example of two merged records from Legacy
<collection>
<record>
<controlfield tag="001">1486099</controlfield>
<controlfield tag="005">20160914115512.0</controlfield>
<datafield tag="035" ind1=" " ind2=" ">
<subfield code="9">INSPIRETeX</subfield>
<subfield code="a">Humbert:2016xbp</subfield>
</datafield>
<datafield tag="100" ind1=" " ind2=" ">
<subfield code="a">Humbert, Pascal</subfield>
#!/usr/bin/python
##########################################################
## grpbibedit.py
## pulls data down from RT
## 2013-05-11 created by BH
## 2014 adapted by MS
## 2015-06-16 updated by BH
##
## hosted at:
## test: https://tislnx3.slac.stanford.edu/cgi-bin/testgrpbibedit.py
This XML file does not appear to have any style information associated with it. The document tree is shown below.
<collection xmlns="http://www.loc.gov/MARC21/slim">
<record>
<datafield tag="035" ind1=" " ind2=" ">
<subfield code="9">arXiv</subfield>
<subfield code="a">oai:arXiv.org:1611.05165</subfield>
</datafield>
<datafield tag="037" ind1=" " ind2=" ">
<subfield code="9">arXiv</subfield>
<subfield code="a">arXiv:1611.05165</subfield>
This XML file does not appear to have any style information associated with it. The document tree is shown below.
<collection xmlns="http://www.loc.gov/MARC21/slim">
<record>
<datafield tag="035" ind1=" " ind2=" ">
<subfield code="9">arXiv</subfield>
<subfield code="a">oai:arXiv.org:1611.05330</subfield>
</datafield>
<datafield tag="037" ind1=" " ind2=" ">
<subfield code="9">arXiv</subfield>
<subfield code="a">arXiv:1611.05330</subfield>
From 01060edd4b946823fb5799b0c78edf6afb70da36 Mon Sep 17 00:00:00 2001
From: Micha Moskovic <michamos@gmail.com>
Date: Wed, 30 Nov 2016 15:39:24 +0100
Subject: [PATCH] api: correct handling of non-ascii references
Signed-off-by: Micha Moskovic <michamos@gmail.com>
kbs: report numbers update
* Add new often cited report numbers, found with
This file has been truncated, but you can view the full file.
{
"Bergamo U., Ingengneria Dept.": [
"Department of Engineering and Applied Sciences - U. of Bergamo - Via Marconi 5 - Dalmine (BG) - Italy",
"U. of Bergamo Viale Marconi 5 - I-24044 Dalmine (BG) - Italy",
"Universit&#x00E0; di Bergamo, Dipartimento di Ingegneria e Scienze Applicate, Viale Marconi 5, I- 24044 Dalmine (BG), Italy",
"Universita degli Studi di Bergamo - Italy",
"U. of Bergamo - Via Marconi 5 - Dalmine (BG) - Italy"
],
"Hasylab, DESY": [
"DESY Theory Group",