This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # note, the links themselves are not in the db, just the stats about them | |
| # I didn't have enough memory, even w/ redis vm, to load the actual links too | |
| wget http://inkdroid.org/data/wikipedia-extlinks.rdb | |
| sudo aptitude install redis-server | |
| sudo mv wikipedia-extlinks.rdb /var/lib/redis/dump.rdb | |
| sudo chown redis:redis /var/lib/redis/dump.rdb | |
| sudo /etc/init.d/redis-server restart | |
| sudo pip install redis # or easy_install (version in apt is kinda old) | |
| ed@rorty:~$ python |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ed@rorty:~$ datapkg info ckan://linkedlccn | |
| ## Package: linkedlccn | |
| id: d9d8a9c5-622c-4085-80f3-308f597d05aa | |
| name: linkedlccn | |
| title: LinkedLCCN | |
| version: 1 | |
| license: OKD Compliant::Other (Public Domain) | |
| author: Ross Singer | |
| author_email: rossfsinger@gmail.com |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from cts.srb import ServiceRequest, ServiceRequestList | |
| from cts.client import get_http_client | |
| http = get_http_client(endpoint=settings.CTS) | |
| http.add_credentials(settings.CTS_USER, settings.CTS_PASSWORD) | |
| task = ServiceRequest.accept_next_from_queue(queue="sampler", | |
| serviceType="bag.QualityReviewBag.review", | |
| http=http) | |
| print task |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Traceback (most recent call last): | |
| File "<console>", line 1, in <module> | |
| File "/home/esummers/projects/sampler/sampler/transfer.py", line 60, in tasks | |
| http=http) | |
| File "/home/esummers/.virtualenvs/sampler/src/pycts/cts/srb.py", line 169, in accept_next_from_queue | |
| sr.update_from_response(sr._location, headers, data) | |
| File "/home/esummers/.virtualenvs/sampler/src/pycts/cts/base.py", line 51, in update_from_response | |
| super(TransferObject, self).update_from_response(url, headers, data) | |
| File "/home/esummers/.virtualenvs/sampler/lib/python2.6/site-packages/remoteobjects/promise.py", line 231, in update_from_response | |
| super(PromiseObject, self).update_from_response(url, response, content) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ed@li144-162:~$ mysql -u root -p | |
| Enter password: | |
| Welcome to the MySQL monitor. Commands end with ; or \g. | |
| Your MySQL connection id is 52868 | |
| Server version: 5.1.41-3ubuntu12.9-log (Ubuntu) | |
| Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. | |
| mysql> create database test; | |
| Query OK, 1 row affected (0.30 sec) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ================================================================================ | |
| Backend error message | |
| --------------------- | |
| Error: in | |
| Pig Stack Trace | |
| --------------- | |
| ERROR 2997: Unable to recreate exception from backed error: Error: in | |
| org.apache.pig.impl.logicalLayer.FrontendException: ERROR 1066: Unable to open iterator for alias b. Backend error : Unable to recreate exception from backed error: Error: in |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?xml version="1.0" encoding="utf-8"?> | |
| <rdf:RDF | |
| xmlns:bibo="http://purl.org/ontology/bibo/" | |
| xmlns:dc="http://purl.org/dc/elements/" | |
| xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"> | |
| <bibo:Book rdf:about="http://catalog.hathitrust.org/Record/006055265#item"> | |
| <dc:creator>Burton, Robert, 1577-1640.</dc:creator> | |
| <dc:subject>Melancholy</dc:subject> | |
| <dc:title>The anatomy of melancholy</dc:title> | |
| </bibo:Book> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @prefix foaf <http://xmlns.com/foaf/0.1/> . | |
| @prefix arch <http://purl.org/archival/vocab/arch#> . | |
| <http://viaf.org/viaf/15572358/#foaf:Person> | |
| a foaf:Person ; | |
| foaf:name "Bush, Vannevar, 1890-1974." ; | |
| arch:appearsWith <http://viaf.org/viaf/21341544/#foaf:Person>, <http://viaf.org/viaf/30867998/#foaf:Person>, <http://viaf.org/viaf/5076979/#foaf:Person>, <http://viaf.org/viaf/6653121/#foaf:Person>, <http://viaf.org/viaf/79397853/#foaf:Person> ; | |
| arch:correspondedWith <http://viaf.org/viaf/13632081/#foaf:Person>, <http://viaf.org/viaf/16555764/#foaf:Person>, <http://viaf.org/viaf/18495018/#foaf:Person>, <http://viaf.org/viaf/20482758/#foaf:Person>, <http://viaf.org/viaf/20994992/#foaf:Person>, <http://viaf.org/viaf/32065073/#foaf:Person>, <http://viaf.org/viaf/41170431/#foaf:Person>, <http://viaf.org/viaf/44376228/#foaf:Person>, <http://viaf.org/viaf/46092803/#foaf:Person>, <http://viaf.org/viaf/49966637/#foaf:Person>, <http://viaf.org/viaf/51816245/#foaf:Person>, <http://viaf.org/viaf/52483290/#f |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ed@rorty:~/Projects/geodict$ curl -s http://chroniclingamerica.loc.gov/lccn/sn84026749/1911-03-30/ed-1/seq-1/ocr.txt | ./geodict.py | |
| New York | |
| New York | |
| New York | |
| Washington | |
| United States | |
| Mexico | |
| Mexico | |
| Washington | |
| Mexico |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| """ | |
| twitter2pinboard.py is a little hack to help you build your pinboard | |
| network based on your Twitter social network. I imagine pinboard will | |
| be adding something like this shortly since they've got some beta Twitter | |
| support now. So rather than turning this into a full on webapp it's just | |
| a command line tool for now. | |
| twitter2pinboard.py uses the Twitter API to look up your friends (people you |