Skip to content

Instantly share code, notes, and snippets.

View tingletech's full-sized avatar

Brian Tingle tingletech

View GitHub Profile
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import argparse
import os
import sys
import json
from urllib.parse import urlparse
import boto3
from pyspark.sql import SparkSession
from icecream import ic
@Grab('com.hp.hpl.jena:jena:2.6.4')
@Grab('com.hp.hpl.jena:arq:2.8.8')
import groovy.sparql.Sparql
// Can also take a Jena model as an argument
def sparql = new Sparql("http://dbpedia.org/sparql")
def query = """
SELECT ?abstract
@tingletech
tingletech / full_path.txt
Last active February 29, 2016 23:33 — forked from aturner/gist:8c7594e7de0d0464d56d
List of files referenced in UCI's Canto Cumulus metadata records, where we didn't obtain/receive a copy of the file on the hard drive (and hence the file is not in Nuxeo).
"/asset-library/UCI/SCA_UniversityArchives/Collection/AS-055/AS-055_b1_f6_001.tif"
"/asset-library/UCI/SCA_UniversityArchives/Collection/AS-055/AS-055_b1_f6_013.tif"
"/asset-library/UCI/SCA_UniversityArchives/Collection/AS-055/AS-055_b1_f6_028.tif"
"/asset-library/UCI/SCA_UniversityArchives/Faculty_Chancellors/Rowland,_F._Sherwood/UCI_A.mov"
"/asset-library/UCI/SCA_UniversityArchives/Collection/AS-136/UCI_AS_136.mp4"
"/asset-library/UCI/SCA_UniversityArchives/Faculty_Chancellors/Rowland,_F._Sherwood/UCI_B.mov"
"/asset-library/UCI/SCA_UniversityArchives/Faculty_Chancellors/Rowland,_F._Sherwood/UCI_C.mov"
"/asset-library/UCI/SCA_UniversityArchives/Faculty_Chancellors/Rowland,_F._Sherwood/UCI_D.mov"
"/asset-library/UCI/SCA_UniversityArchives/Faculty_Chancellors/Rowland,_F._Sherwood/UCI_E.mov"
"/asset-library/UCI/SCA_UniversityArchives/Faculty_Chancellors/Rowland,_F._Sherwood/UCI_F.mov"
@tingletech
tingletech / banner-img.png
Last active November 16, 2015 20:02 — forked from amywieliczka/banner-img.png
Banner for the old Calisphere
banner-img.png
@tingletech
tingletech / x.json
Created June 26, 2015 17:35 — forked from mredar/x
{
"responseHeader":{
"status":0,
"QTime":112,
"params":{
"facet.query":"true",
"q":"-reference_image_md5:[* TO *]",
"facet.field":"collection_url",
"indent":"true",
"fq":"type_ss:\"image\"",
<http://www.w3.org/2001/XMLSchema#date> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2000/01/rdf-schema#Datatype> .
<http://library.ucsd.edu/ontology/dams/#Associated_name> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2002/07/owl#NamedIndividual> .
<http://library.ucsd.edu/ontology/dams/#Associated_name> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://library.ucsd.edu/ontology/dams/#Role> .
<http://library.ucsd.edu/ontology/dams/#Associated_name> <http://www.w3.org/2000/01/rdf-schema#label> "associated_name"@en .
<http://library.ucsd.edu/ontology/dams/#Associated_name> <http://library.ucsd.edu/ontology/dams/#code> "asn"^^<http://www.w3.org/2001/XMLSchema#string> .
<http://library.ucsd.edu/ontology/dams/#Associated_name> <http://library.ucsd.edu/ontology/dams/#value> "associated name"^^<http://www.w3.org/2001/XMLSchema#string> .
<http://library.ucsd.edu/ontology/dams/#Associated_name> <http://library.ucsd.edu/ontology/dams/#authorityURI> "http://www.loc
@tingletech
tingletech / README.md
Created November 19, 2012 00:03 — forked from mbostock/.block
Bayesian Javascript Example
@tingletech
tingletech / curl-response.log
Created November 2, 2012 17:27 — forked from anarchivist/curl-response.log
ArchivesSpace 0.2.0-1 front end gives empty results
BRIAN-TINGLEs-MacBook-Air:~ tingle$ java -version
java version "1.6.0_37"
Java(TM) SE Runtime Environment (build 1.6.0_37-b06-434-11M3909)
Java HotSpot(TM) 64-Bit Server VM (build 20.12-b01-434, mixed mode)
BRIAN-TINGLEs-MacBook-Air:~ tingle$ uname -a
Darwin BRIAN-TINGLEs-MacBook-Air.local 11.4.2 Darwin Kernel Version 11.4.2: Thu Aug 23 16:25:48 PDT 2012; root:xnu-1699.32.7~1/RELEASE_X86_64 x86_64
BRIAN-TINGLEs-MacBook-Air:~ tingle$ sw_vers
ProductName: Mac OS X
ProductVersion: 10.7.5
BuildVersion: 11G63