GithubHelp home page GithubHelp logo

pwallace / metadata-processing-legacy Goto Github PK

View Code? Open in Web Editor NEW
5.0 2.0 0.0 38 KB

Dumping ground for scripts that I've used for various repository management & metadata processing tasks at work -- mostly for Internet Archive (archive.org) and migrating out of an old local version of CONTENTdm.

License: GNU General Public License v3.0

Python 100.00%
metadata parser contentdm internet-archive omeka

metadata-processing-legacy's Introduction

note: this collection of scripts is unmaintained, and most were written using significantly older versions of their component libraries than currently available. A number are also still Python2.x and unlikely to be updated.

metadata-processing


SCRIPT: ia_check_missing_metadata.py

DEPENDS ON: https://github.com/jjjake/internetarchive

PURPOSE: Checks for a given metadata element in Internet Archive item records. Returns a list of item identifiers for records in which the element DOES NOT appear.

USAGE: python ia_check_missing_metadata.py [list-of-identifiers.txt] [metadata element label]


SCRIPT: ia-search.py

DEPENDS ON: https://github.com/jjjake/internetarchive

PURPOSE: Returns a list of item identifiers in an Internet Archive collection.

USAGE: python ia-search.py [collection_to_search]


SCRIPT: ia-file-list.py

DEPENDS ON: https://github.com/jjjake/internetarchive

PURPOSE: Searches an Internet Archive collection for a string in identifier, returns first filename associated with identifier.

USAGE: python ia-file-list.py [collection_to_search] [search_string]


SCRIPT: ia-json.py

DEPENDS ON: https://github.com/jjjake/internetarchive

PURPOSE: Dumps JSON to for items within an Internet Archive collection

USAGE: python ia-json.py [collection_to_scrape] [outfile.json]


SCRIPT: iaCollectionCSVer.py

DEPENDS ON: https://github.com/jjjake/internetarchive

PURPOSE: to facilitate bulk update of extant Internet Archive items to a include a new collection.

PERFORMS THE FOLLOWING:

  1. Searches an existing IA collection for items with matching [search_string] in "title", "description", or "subject" fields.
  2. Fetches object metadata and appends a new collection field
  3. Outputs a CSV intended for re-upload with the internetarchive command line tool.

USAGE: python iaCollectionCSVer.py [search_string] [name_of-collection_to_search] [name_of_new_collection] [outfile.csv]


SCRIPT: ia-fetch-subjects.py

DEPENDS ON: https://github.com/jjjake/internetarchive

PURPOSE: Outputs a CSV containing [IDENTIFIER, TITLE, SUBJECT[0], SUBJECT[1], etc...]

USAGE: python ia-fetch-subjects.py [collection_to_search] [outfile.csv]


SCRIPT(s): cdm_x_dump.py

PURPOSE: Fetches & dumps objects from CONTENTdm via an XML file created with pyoaiharvester.

SEE: https://github.com/vphill/pyoaiharvester

XML File Creation: python pyoaiharvest.py -l [http://server.domain.edu:port/oai/oai.php] -o [outfile.xml] -m [CONTENTdm_collectionID]

DEPENDS ON:

  1. urllib2
  2. etree

USAGE: python script.py [IA_collection_ID] [outfile.csv]

NOTE: The Omeka CSV importer wants only items of a single type (e.g., still images, documents, etc). This script presumes all items in a collection are of mediatype:image (i.e., still images in jpg format).


SCRIPT: ia2omeka.py

DEPENDS ON: https://github.com/jjjake/internetarchive

PURPOSE: Outputs a CSV from an Internet Archive suitable for ingest into Omeka. Allows for easy migration/generation of Omeka collections from items in IA.

USAGE: python ia2omeka.py [IA_collection_ID] [outfile.csv]


SCRIPT: rm2mp4.py

DEPENDS ON:

  1. ffmpeg (or avconv)
  2. mplayer
  3. libx264
  4. libfaac
  5. a plaintext list of URLs for the RealMedia streams

PURPOSE: Dump RealMedia streeams from server and convert to mp4 audio

USAGE: python script.py [urllist.txt]

NOTE: this method is SLOOOOOOW and wonky and resource-heavy. The time to download and convert a .rm video is around 130% of the playback duration.


SCRIPT: fastimagecat.py

DEPENDS ON:

  1. feh, PIL, or TerminalImageViewer (https://github.com/stefanhaustein/TerminalImageViewer) depending on preference
  2. json

PURPOSE: To speed descriptive data entry for large image batches. Reads "default.json" (see example below) and queries empty values (i.e., reads each key, if key = "" asks for user input). Creates descriptive metadata for each image in a directory as individual JSON files based on user input.

USAGE: python script.py [working_directory]

EXAMPLE CONFIG (named "defaults.json", will ask user for title, creator, and date): { "collection" : "this collection", "rights" : "This image licesed under a CC-4.0-By license." "title" : "" "creator" : "" "date" : "" }

metadata-processing-legacy's People

Contributors

pwallace avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

metadata-processing-legacy's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.