Automatically build still image objects from template (Target)
- Julie Wetherill
- Emily Kelly
- Former user (Deleted)
Â
Overview
This is a description of the procedure to automatically build a batch of target image objects from template using Batch Builder 2 (BB). Use this method if you have a large number of objects (more than 10) that need to be created and your source files are not broken into directories by object.
Procedure summary:
- Create a new project.
- Enter DRS deposit information.
- Create the object template.
- Add directories to the object template.
- Repeat steps in (4) for additional nested directories if needed.
- Save your work
- Move/copy images into the object template.
- Create a new object batch.
- Process the batch.
What you need before you start:
- Prepare digital images and put them in a directory of your choice somewhere on local hard disk or network drive. If you have more than one file per image (e.g.: an archival master and a deliverable or an archival master, a deliverable and a thumbnail) make sure file names match (e.g.: image-1.tif, image-1.jp2 and image-1.jpg).
- Decide what you will use for owner supplied names for target image objects and the digital files they consist of. For instance, you could use local classification or local accession numbers. Consult Naming rules for files, objects and directories of this Guide for more information.
- Make sure you either provide object name prefixes for each file to specify which objects it should be assigned to (The syntax is: [obj-osn]--[file_name].[extension]) or provide object assignment for your file in an external mapping file. For more details about providing object prefixes for your files see the File name pattern options section of Installation and Setup. For more details about external mapping files see Using mapping.txt File.
Procedure:
Start at Step 5 if you are reusing a project to generate a new batch.
- Create new project in Batch Builder
- From main menu select Project > New.
- Enter project data:
Project Name: enter a name for your project (used for internal tracking only).
Project Directory: select the directory where project will be saved (click ellipsis button to browse for or create a directory).
TIP: use 'project' as part of the directory name to make it easier to identify later. (e.g. museum_slide_project)
Content Model: select the 'target image' value from the dropdown.
Project Description (optional): Any information relevant to the project – will only remain locally. - Click OK to continue.
- Enter DRS deposit settings:
- Click on "Deposit Settings" in Project Panel tree.
- Enter deposit data in the form:
Batch Name Pattern: default - {owner}{batchDir}{yyyy}{mo}{dd}_{hh24}{mm}{ss}
(This is the name for a batch that appears on DRS deposit reports. Batch name must be at least 3 characters long.)
Success Email: type email and press enter.Â
Failure Email: type email and press enter.Â
Success Method: choose how you will receive load report.Â
Deposit Agent: type your HUID.
Deposit Agent Email:Â type your official Harvard email address.
- Create object template:
Metadata added at this level will be applied to every object in a batch, unless overridden by specific object metadata that you define in later steps.- Click on "Object Template" in Project Panel tree:
- Enter required object metadata in the form:
DRS Owner Code: your owner code (use all caps).Â
DRS Billing Code: your billing code (use all caps).
Object Access: the DRS access flag. At this level, select the least restrictive value if the batch will contain a mix of public and restricted files.Â
URN Authority Path: your NRS authority path. Use all caps. Look up your Path here if needed: http://nrs.harvard.edu/urn-3:hul.ois:nrsstatusprod.Â
File URN Resource Name Pattern: use default value {n} to generate a unique number. - Switch to "optional" tab to enter any optional metadata (for example, descriptive metadata, roles and relationships that will apply to your objects). For more about optional metadata see Sections 9. Adding Relationships, 10. Adding Descriptive Metadata, 11. Adding Supporting Content.
- Add image directory to template:
- Right click on "OBJECT TEMPLATE" in the Project Panel on the left and select the 'add a directory…" menu option.
- Type in a name for your directory in the text box . The directory name will start with "image" but the name you type will be appended to it. Tip: to make it easier to read, start your directory name with an underscore (_) So, typing '_tifs_and_jpegs' will result in a directory called 'image_tifs_and_jpegs'
- In the Project Panel on the left select the directory you just created.
- In the Content Panel on the right, choose "yes" from the dropdown list for the field "First Generation in DRS".
- Choose "LOWUSE" for Usage Class.
Add additional metadata (optional tab):
- Select the new directory in the Project Panel on the left
- In the Content Panel, select the 'optional' tab.
- Scroll down to "Still Image File Metadata "
- Enter any file level optional metadata in the form
5. Add target description file (tdf) directory:
- Right click on "OBJECT TEMPLATE" in the Project Panel on the left and select the 'add a directory…" menu option.
- Select 'tdf' from the drop down menu next to 'directory name'.
- Type in a name for your directory in the text box. The directory name will start with 'tdf' but the name you type will be appended to it. In the Project Panel on the left select the directory you just created.
- In the Content Panel on the right, choose "yes" from the dropdown list for the field "First Generation in DRS".
- Choose "LOWUSE" for Usage Class.
Add additional metadata (optional tab):
- Select the new directory in the Project Panel on the left
- In the Content Panel, select the 'optional' tab.
- Scroll down to "Target Image File Metadata"
- Enter any file level optional metadata in the form.
6. Save your work (Project > Save on main menu).
7. Copy image files and optional target description files into Batch Builder template directories on disk (can be done outside Batch Builder).
The directories you created in BB have been created on disk, in the project's template path:Â {project_name}\template\
In order to tell BB which object each file should end up with you need to either add object name prefixes to each file name or supply a mapping.txt file that associates each file with its future object. See Naming Rules for Objects for how to add an object name prefix. See Using mapping.txt File for how to create a mapping file.
In the automatic workflow, files with the same role (image, tdf) are copied into the corresponding role-based directory. In a later step, Batch Builder will use the object name prefix for each file to create object directories and move files for each object into these directories.
Note: if you need to check where the directories are on disk, click on "Deposit Settings" in the Project Panel tree and look at the Project Path field at bottom.
** Quick way to copy content files: you can drag files from your file system onto the object template directories in the Batch Builder project panel.
** If using mapping.txt, this is when you should copy it to the auxiliary template path in the project.
** If including external MODS descriptive metadata, this is when you should copy it to the auxiliary template path in the project.
Â
8. Create a new object batch.
    You can create your new object batch in the Graphical User Interface or using the Command Line Interface (CLI).
    In the Graphical User Interface
- From the Object menu in BB select "Create a new batch with objects from template"; enter the name of the batch directory to be created on disk and click OK. A new batch icon will be added to the Project Panel on the right (icon with a red letter B) and new objects will be built that are going to be part of this batch.
- In the Project Panel click on the "+" next to the Batch icon of the batch you just created to expand the tree – it will show the icons for the new objects (a blue letter O).
- (Optional) Select the object icon of your new object in the Project Panel and switch to "optional" tab in the Content Panel to enter any optional metadata (for example descriptive metadata, roles or/and relationships that will apply to your objects). For more about optional metadata see sections 9. Adding Relationships, 10. Adding Descriptive Metadata, 11. Adding Supporting Content. Note that any metadata entered at the object level will override metadata entered at the template level.
- Save the project to have BB2 write the new metadata values to the internal configuration files.
  In the Command Line Interface
- In the command line window (Terminal on Mac or Linux or CMD on Windows) change to the BB installation directory, e.g.: cd C:\Program Files\BatchBuilder\BatchBuilder-2.0.45
Typebathcbuildercli –a buildtemplate –p [project_directory_path] –b [batch_directory_name]
, e.g.:Â batchbuildercli -a buildtemplate -p "E:\My Project" -b batch1
Note that the batch directory name is the name of your new batch directory, to be created by BB. - If the batch creation is successful you will see the following messages:
Initializing BB...
Done!
Creating batch1 and objects from files in the template...
Success!
- In the command line window (Terminal on Mac or Linux or CMD on Windows) change to the BB installation directory, e.g.: cd C:\Program Files\BatchBuilder\BatchBuilder-2.0.45
9. Process the batch.
    You can process your batch in the Graphical User Interface (GUI) or using the Command Line Interface (CLI).
    In the In the Graphical User Interface
- In the Project Panel on the left right-click on the batch you want to process (batch icon with a red letter B) and select "Create descriptors and batch.xml."
- Builder will start processing the batch.
- When the batch is successfully processed you will see the following message: FINISHED - Creation of batch.xml and descriptors complete for batch ….
If you see any error messages, remedy the errors and re-process the batch.
In the Command Line Interface
- In the command line window (Terminal on Mac or Linux or CMD on Windows) change to the BB installation directory, e.g.: cd C:\Program Files\BatchBuilder\BatchBuilder-2.0.45
- Type
bathcbuildercli –a build –p [project_directory_path] –b [batch_directory_name]
, e.g.: batchbuildercli -a build -p "E:\My Project" -b batch1 - (Optional) add additional parameters to the bathcbuildercli command to substitute batch, object and directory level properties. For more information see Processing Batches Using Command Line Interface.
- When the batch is successfully processed you will see the following messages:
Building PREMIS file metadata...
Building HulDrsAdmin file metadata...
Success!
If you see any error messages at the end of batch processing, remedy the errors and re-process the batch (you can disregard any errors showing during batch processing on command line as long as you get the final "Success!" message).
On this page: