1. Help Center
  2. Layout Recognition

8. P2PaLA

This functionality has been replaced by Field Models, which require less training data and provide more precise outcomes than P2PaLA.


 

Transkribus eXpert (deprecated)

P2PaLA is a Layout Analysis tool that recognises structure types on a region and line level based on pre-trained models.

First, you need to add structural tags on some pages to create the training data; then, you can train a P2PaLA model able to recognise the structure of new pages of your documents automatically.

The model's efficiency will depend on the quality of the training data. If you have tagged about 50 examples of every structure type, which should be trained, this should be fair enough to start training, so 50-100 pages of training material should be suitable to create a useful model. Of course, it is possible to start training earlier, with a decrease in efficiency.

You don't need to tag every feature of your documents; you should focus on marking up the sections that interest you. The structural tagging interface can be found by clicking the "Metadata" tab in the Magaing&Tools Bar and then the "Structural" tab.

Click on a text or line region in your document that you want to tag with a structural type. You can select several regions at once by holding down the "CTRL" key on your keyboard and then clicking the shapes. Then, to add the structural tag, either click the green plus button on the right of the desired tag category in the "Structural" tab or right-click the selected shape in your document and choose the desired tag under "Assign structure type". The Structural Tags page explains in more detail how structural tags work. 

After finishing the tagging process of 50-100 pages (at least 50 examples of every structure type), you can start training. For this, open the "Tools" tab in the Managing&Tools bar and click the "P2PaLA" button in the "Other tools" section. In the opening window, click "Train" and the training parameters will open up.

The settings you need to configure are:

  • "Structures":  add the structure types which should be trained. Click the green plus button to enter them.
  • "Merged Structures": are used to treat specific structure types the same as others during training (e.g. 'footnote-continued' or 'footer' like 'footnote'). Click the green plus button to select the base structure and the merged structure (the one treated equally to the base structure).
  • "Training mode": you can decide if you would like to train regions only, lines only or both.
  • "Edit status": if you would like to use the latest version, you don't need to choose anything; otherwise, you can choose which status of the document should be trained.
  • "Training set" is where to choose the training data.
  • "Analyse structure types": gives an overview of the number and types of structure tags within the chosen document.

To start the training, click "Train". After the training process is finished, the P2PaLA model is available for your collection and can be shared with other collections too.

If you would like to apply a structure model to a document in order to let structure types be recognised, open the "P2PaLA" tool within the "Tools" tab.

Choose the pages to recognise and select a P2PaLA model. To see the available models, first, you need to click on the appropriate Model filter: "Collection" (when the desired model is in your collection), "User" (when you have trained the model), "Public models" (if you would like to use a public model). After choosing one of the options, the available models will appear next to: "Select a model for recognition". Choose the model you would like to use. You can get an overview of all the models by clicking on "Models".

You have now to choose one of two options:

  • "Create New Layout": a new version with a new layout is created, and the existing layout will be lost.
    If you tick "Rectify regions," all regions will be simplified to the bounding box of the actual recognised shape. The "Min area" parameter is used to remove small "garbage" regions. Shapes with an *area* smaller than this fraction of the image *width* will be removed after the recognition. The default value is 0.01.
  • "Label existing transcriptions": the existing layout of the latest version will be labelled with the structure types. You can choose to label regions, lines and words according to the tags the model was trained on. 

To start the recognition, click "Run".