hcts-hra / ecpo-annotator

Annotator for Page Segmentations in ECPO
https://ecpo.existsolutions.com/exist/apps/ecpo/
MIT License
2 stars 2 forks source link
cjk exist-db polymer2 segmentation xml xquery

Image annotation tool

This is an eXist-db-based application that allows graphical image annotation.

Users can draw different shapes on top of images (rectangles, circles, polygons) and store these selections as part of an standoff annotation which will contain the selections as SVG.

The app provides the following functions:

The separate WAP app implements the basics of the Web Annotation Protocol to allow storage of the standoff annotations.

Implemenation Notes

The application is built as an eXist-db application and relies on Polymer 2.0 Web Components in the frontend.

Requirements and Dependencies

Building the app

Install npm and bower dependencies

npm install
bower install

The app is then built via Ant with this command:

ant xar

Since the xar task is the default you can also just call

ant

Development

gulpfile.js in the project root defines two tasks gulp deploy and gulp watch that lets you upload and test changes you made to the code without having to package and install ecpo each time.

For this to work you might have to adapt the connection settings on your local checkout to match your settings.

NOTE: do not commit those changes

The default connection settings are:

const exClient = exist.createClient({
    host: 'localhost',
    port: '8080',
    path: '/exist/xmlrpc',
    basic_auth: {user: 'admin', pass: ''}
})