war stories: programming in the field of medieval history

51
War Stories Programming in the field of Medieval History Tara L Andrews (@tla) Assistant Professor of Digital Humanities, University of Bern

Upload: tla

Post on 14-Apr-2017

462 views

Category:

Engineering


1 download

TRANSCRIPT

Page 1: War stories: Programming in the field of medieval history

War Stories

Programming in the field of Medieval History

Tara L Andrews (@tla) Assistant Professor of Digital Humanities, University of Bern

Page 2: War stories: Programming in the field of medieval history
Page 3: War stories: Programming in the field of medieval history
Page 4: War stories: Programming in the field of medieval history
Page 5: War stories: Programming in the field of medieval history
Page 6: War stories: Programming in the field of medieval history

How do we write history?

Page 7: War stories: Programming in the field of medieval history
Page 8: War stories: Programming in the field of medieval history
Page 9: War stories: Programming in the field of medieval history
Page 10: War stories: Programming in the field of medieval history
Page 11: War stories: Programming in the field of medieval history

Matthew of Edessa

He went through the wars. And then his text did, too.

Page 12: War stories: Programming in the field of medieval history
Page 13: War stories: Programming in the field of medieval history
Page 14: War stories: Programming in the field of medieval history
Page 15: War stories: Programming in the field of medieval history
Page 16: War stories: Programming in the field of medieval history
Page 17: War stories: Programming in the field of medieval history
Page 18: War stories: Programming in the field of medieval history
Page 19: War stories: Programming in the field of medieval history
Page 20: War stories: Programming in the field of medieval history
Page 21: War stories: Programming in the field of medieval history
Page 22: War stories: Programming in the field of medieval history

Interlude: A fragile history

Page 23: War stories: Programming in the field of medieval history
Page 24: War stories: Programming in the field of medieval history
Page 25: War stories: Programming in the field of medieval history
Page 26: War stories: Programming in the field of medieval history

package Text::Tradition::Collation::Data; use Moose; use Graph; use Text::Tradition::Datatypes;

has 'sequence' => ( is => 'ro', isa => 'Graph', default => sub { Graph->new() }, handles => { paths => 'edges', }, ); has 'relations' => ( is => 'ro', isa => 'Text::Tradition::Collation::RelationshipStore', handles => { relationships => 'relationships', related_readings => 'related_readings', get_relationship => 'get_relationship', del_relationship => 'del_relationship', equivalence => 'equivalence', equivalence_graph => 'equivalence_graph', relationship_types => 'types' }, writer => '_set_relations', );

Page 27: War stories: Programming in the field of medieval history
Page 28: War stories: Programming in the field of medieval history

package Text::Tradition::Directory;

use strict; use warnings; use Moose; use DBI; use Encode qw/ encode decode_utf8 /; use KiokuDB::GC::Naive; use KiokuDB::TypeMap; use KiokuDB::TypeMap::Entry::Naive; use Safe::Isa; use Text::Tradition::Error;

## users use KiokuX::User::Util qw(crypt_password); use Text::Tradition::Store; use Text::Tradition::User; use Text::Tradition::TypeMap::Entry;

extends 'KiokuX::Model';

use vars qw/ $VERSION /; $VERSION = "1.2";

=head1 NAME

Text::Tradition::Directory - a KiokuDB interface for storing and retrieving traditions and their owners

=head1 SYNOPSIS

Page 29: War stories: Programming in the field of medieval history

[warn] leaked objects: .--------------------------------------------------------------+----------. | Class | Count | +--------------------------------------------------------------+----------+ | Text::Tradition::Collation::Data | 1 | '--------------------------------------------------------------+----------' [warn] leaked objects: .--------------------------------------------------------------+----------. | Class | Count | +--------------------------------------------------------------+----------+ | Text::Tradition::Collation::Data | 1 | '--------------------------------------------------------------+----------' [warn] leaked objects: .--------------------------------------------------------------+----------. | Class | Count | +--------------------------------------------------------------+----------+ | Text::Tradition::Collation::Data | 6 | '--------------------------------------------------------------+----------' [warn] leaked objects: .--------------------------------------------------------------+----------. | Class | Count | +--------------------------------------------------------------+----------+ | Text::Tradition::Collation::Data | 1 | '--------------------------------------------------------------+----------' [warn] leaked objects: .--------------------------------------------------------------+----------. | Class | Count | +--------------------------------------------------------------+----------+ | Text::Tradition::Collation::Data | 6 | '--------------------------------------------------------------+----------' [error] Caught exception in stemmaweb::Controller::Relation->main "Cannot allocate memory during fork at /usr/local/share/perl/5.18.2/Text/Tradition/Collation.pm line 976."

Page 30: War stories: Programming in the field of medieval history

Testing. A cute idea.Mac-c8e0eb150215:base tla$ prove -l t/*.t t/00dependencies.t .............................. ok t/01app.t ....................................... ok t/02pod.t ....................................... ok t/03podcoverage.t ............................... skipped: set TEST_POD to enable this test t/text_tradition.t .............................. ok t/text_tradition_collation.t .................... ok t/text_tradition_collation_relationshipstore.t .. ok t/text_tradition_parser_collatex.t .............. ok t/text_tradition_parser_json.t .................. ok t/text_tradition_parser_self.t .................. ok t/text_tradition_parser_tabular.t ............... ok t/text_tradition_parser_tei.t ................... ok t/text_tradition_witness.t ...................... ok All tests successful. Files=13, Tests=556, 43 wallclock secs ( 0.10 usr 0.03 sys + 40.60 cusr 1.12 csys = 41.85 CPU) Result: PASS

Page 31: War stories: Programming in the field of medieval history

Digital Humanities tenure submission

Page 32: War stories: Programming in the field of medieval history
Page 33: War stories: Programming in the field of medieval history

Textual criticismA war of methodology

Page 34: War stories: Programming in the field of medieval history
Page 35: War stories: Programming in the field of medieval history
Page 36: War stories: Programming in the field of medieval history
Page 37: War stories: Programming in the field of medieval history
Page 38: War stories: Programming in the field of medieval history
Page 39: War stories: Programming in the field of medieval history
Page 40: War stories: Programming in the field of medieval history
Page 41: War stories: Programming in the field of medieval history

Interlude #2: We really have problems.

Page 42: War stories: Programming in the field of medieval history
Page 43: War stories: Programming in the field of medieval history
Page 44: War stories: Programming in the field of medieval history

use strict; use warnings; use feature ‘say’; use WWW::Google::Places; my $api_key = 's33kr1t'; my $place = WWW::Google::Places->new({ api_key => $api_key }); # Google search place my @results = $place->textsearch({ query => $ARGV[0] }); foreach (reverse @results) { say "Id : ", $_->place_id; say "Name : ", $_->name; say "Types : ", join(", ", @{$_->types}); say "Geometry: ", $_->geometry; say "Icon : ", $_->icon; say "Vicinity: ", $_->vicinity; say "Scope : ", $_->scope; say "----------------------------------------"; }

Page 45: War stories: Programming in the field of medieval history

---------------------------------------- Id : ChIJsX7lyvNMSIgRVXRTNgaDlb0 Name : Gihon Elementary School Types : school, point_of_interest, establishment Geometry: Location: Latitude: 39.234044, Longitude: -81.552035 Icon : https://maps.gstatic.com/mapfiles/place_api/icons/generic_business-71.png Vicinity: N/A Scope : GOOGLE ---------------------------------------- Id : ChIJRUzmdd7J5YgR0aKaqFXMhLI Name : Shorstein, Lasnetski, & Gihon Types : lawyer, point_of_interest, establishment Geometry: Location: Latitude: 30.254356, Longitude: -81.627089 Icon : https://maps.gstatic.com/mapfiles/place_api/icons/generic_business-71.png Vicinity: N/A Scope : GOOGLE ---------------------------------------- Id : ChIJYbwjTt06K4gRuKL-IX6oTy0 Name : Gihon Spring Park Types : park, point_of_interest, establishment Geometry: Location: Latitude: 43.754475, Longitude: -79.594406 Icon : https://maps.gstatic.com/mapfiles/place_api/icons/generic_business-71.png Vicinity: N/A Scope : GOOGLE ----------------------------------------

Page 46: War stories: Programming in the field of medieval history
Page 47: War stories: Programming in the field of medieval history

Art or engineering?Skirmishes on the place of

creativity

Page 48: War stories: Programming in the field of medieval history
Page 49: War stories: Programming in the field of medieval history
Page 50: War stories: Programming in the field of medieval history
Page 51: War stories: Programming in the field of medieval history

Thank you! ¡Grácias!