Imaging Workflow Application

The imaging workflow is a Java v7 application for accumulating label images and their associated metadata for submission to the central FTP site in Florida for processing.

Setting up the Workflow Application.

Download Java v7.

Download the workflow application.

This is a zip file containing the java class files that comprise the application and three data files that can be to populate dropdown menus in the application. Once you have saved the zip file on your computer. Right click on the file name and select "Extract All" in the box that opens in response. Record the path to the folder that you extract the files into.

To create a Windows desktop shortcut to the application, right click on the desktop and select New Shortcut.  Enter "java production.ImagingWorkflowApplication" into the textbox labeled "Type the location of the item:".  Click "Next" and enter an appropriate name for the shortcut.  Click "Finish".  Then right click on the desktop shortcut you just created, select “Properties” and enter the path to the folder into which you extracted the workflow into the “Start in” field.  For instance, if you extracted the zip file into the C:\ImagingWorkflow folder and the class files are in the C:\ImagingWorkflow\production folder, enter "C:\ImagingWorkflow" into the "Start in" textbox. Click “OK”.

Using the Workflow Application

Clicking on the shortcut will open a panel with six tabs.  The first tab, labeled "Working Folder", will be displayed. Click on the button labeled "Select a Working Folder" to begin. This allows you to select the folder into which the application saves the images and metadata. Two subfolders within the working folder will be created by the workflow application at this point, "processing" and "destination".  The camera that is used to record the image labels should be set to send the images to the processing folder. Many cameras will automatically create subfolders within this folder but that will not not cause problems with this application. The workflow application will monitor the processing folder and its subfolders for incoming files from the camera. The destination folder will receive the files and their associated metadata files after processing.

After you have selected a working folder click on the "Select Data Sources" tab to select data sources that the application will use to populate dropdown menus containing scientific names (a required field) and exsiccati names (optional). If you click on the "Scientific Name File" option you will be asked to select an authority file.  This file should be a comma- or tab-deliminted file containing the scientific names you would like to have in the scientific name dropdown menu. The lichen_taxa.tab and bryophytes_taxa.tab files included in the application zip file can be used for this purpose.

If you choose to use a text file containing exsiccati names and numbers you can upload it by clicking on the Upload button. You can use the asu_exsiccati_full.tab (which contains column names in the first row) included in the zip file for this purpose.  If you click on the "Column names in first row" checkbox the entries in the first row of the file will appear in the dropdown menu that appears to allow mapping of the appropriate columns of the file to the exsiccati names, exsiccati numbers and scientific names.  Otherwise the dropdown menu will display column numbers. You must select columns for the application to use or the exsiccati dropdowns will not be populated correctly.

When this has been completed click on the "Persist Metadata" tab.  In this tab you can enter metadata that will be persisited between sessions and between images.  The five textboxes at the top allow entry of metadata that will be persisted between sessions. The checkboxes at the bottom allow the selection of metadata that will not be reset between images during data accumulation. Once these have been entered click on the "Enter Data" tab.

Two values are required for every label, barcode and scientific name. The barcode is assumed to come from a barcode reader and the scientific name will come from the Scientific Name dropdown menu. When a selection is made from the Scientific Name dropdown menu two things happen: (1) If an exsiccati name file has been uploaded and its columns correctly mapped, the application will read the exsiccati name file and those rows which have the chosen scientific name in the column which you have mapped as the scientific name column will have the value of the column which you have mapped as the exsiccati name column added to the "Exsiccati" dropdown menu. Subsequently, if a value is selected from the Exsiccati dropdown the file will be read again and those rows which match the selected value will have the values of the column mapped as the exsiccati number added to the Exsiccati Number dropdown menu. (2) If a working folder has been selected a "New Session" button will appear at the bottom of the tab.

When a selection is made from the Country dropdown menu the State/Province dropdown is populated with only those states or provinces which are associated with that country. To repopulate the State/Province dropdown with all of the states regardless of country (only the United States, Canada, Mexico, Norway, Sweden, Denmark and Finland currently have states or provinces associated with them and only those states or provinces will appear in the State/Province dropdown menu) select the empty line at the top of the Country dropdown. When a selection is made in the State/Province dropdown the country it is associated with is selected in the Country dropdown. Both the Country and State/Province dropdown menus are editable so users can enter values currently not in our database.

Clicking on the new session button begins the monitoring of the processing folder for incoming files. A folder is created in the destination folder with the date as its name. Subsequent sessions for a given day have "_1", "_2", etc. appended to the folder name after the date. Also, after clicking this button you can no longer select a new working folder without closing and reopening the application. After the new session button has been clicked new files that are sent to the processing folder by the camera will have their names displayed at the bottom of the tab and if a barcode has been entered "Enter" and "Delete" buttons will appear at the bottom next to the new session button. The delete button will remove all files from the processing folder and its subfolders. The enter button will rename the image file to be the contents of the barcode field, move it to the destination folder and enter its metadata from the application into the metadata file for the session.  If there is more than one file in the processing folder when the enter button is clicked or if the button is clicked twice with the same value in the barcode field the additional files will be named with "_a", "_b", etc. appended to filename after the barcode.  Those fields in the data entry tab that have not been checked in the Persist Metadata tab are cleared and, if it is the first entry for the session, the values of the working folder and the metadata that has been entered in the persist metadata tab are saved in a file that is read in subsequent sessions. After this, if you close the application and reopen it, this file is read and used to set the working folder and populate the dropdown menus and the application will go straight to the Enter Data tab. To change these persisted values you can go the the relevent tabs and reset them before clicking on the New Session button.

The fifth tab is called Manage Data and contains a single "Delete" button that allows the user to remove images from subfolders of the destination folder. When you remove images this way any references to that image in the metadata file are also removed. Only files with the .jpg file extension can be removed. Session folders can also be removed if they are subfolders of the current destination folder unless you try to remove the current session folder.
 

The final tab is called "Archive Data". It is intended to to be used to save accumulated data to an external storage drive. Clicking on the "Archive" button allows the user to select the drive and folder to save the data in. If the "Overwrite" check box is checked all subfolders of the destination folder will be transferred to the archive folder and already-existing files with the same name will be overwritten. If the overwrite checkbox is unchecked only new files will be transferred.

Contact Robert Anglin for assistance in setting up and using this application.

page tag: 

This material is based upon work supported by the National Science Foundation grant ADBC#1115116. Any opinions, findings, conclusions, or
recommendations expressed in the material are those of the author(s) and do not necessarily reflect the views of the National Science Foundation.