Marker Copyright Senthil Arun and Arend Sidow, 2005



Marker Copyright Senthil Arun and Arend Sidow, 2005.

A super-lightweight java program for interactive scoring of features in large image files.

We use it to score sea squirt embryos. You can use it for scoring anything, as long as you have a jpg, png, or gif file. If you have tiff or other types of files you first need to convert them into one of the above formats with a tool such as Photoshop.

You need to know how to use a terminal window, and be capable of basic Unix (including Mac) or windows command-line commands like cd or mv or rm. You need to have Java installed. That’s about it. There are no additional requirements.

Concept

You have a lot of repeated features in an image that differ by some attribute. In our case, it’s the amount of staining in developing sea squirt embryos. An image may contain as many as a hundred embryos, and we want to score them by the amount of staining they exhibit, and in the end we want to count how many are stained strongly, intermediate, weakly, in muscle, in brain, etc.

You, the user, need to devise a simple scoring system by which you assign single letters or digits to some attribute of your choice. In this example, we score embryos by the amount of staining in tail muscle:

[pic]

Section of a larger image file in which five embryos were scored.

When you are done scoring, three files are output:

(1) One tab-delimited output text file that contains the summary. These are the data you’re after. In the case above, this file would look like this:

Char Count

9 3

3 1

1 1

This file has the extension .out.

Example: Your image file was MyImage.jpg.

The output file will be MyImage.out

(2) An image file for archival purposes. This file is only for archival purposes. Never reload this file into Marker. Why not is explained below. This file is called _marked.jpg.

Example: Your original image file was MyImage.jpg.

The archival, marked, image file will be MyImage_marked.jpg.

(3) A tab-delimited coordinates file that records each spot where the original image was marked, and what the character was that marked it there. The X-Y are coordinates in pixels:

Char X Y

3 476 64

1 521 60

9 495 104

9 415 146

9 473 140

The purpose of this file is to be able to edit your scoring at a later point. This file has the extension .crd.

Example: Your image file was MyImage.jpg.

The coordinates file will be MyImage.crd.

Usage, Details, and Manual

To run:

java -cp Marker.jar Marker

There are a few rules.

Rule 1: If there is a crd file present, Marker will load it and present you with the marked image. The marks can be edited. If there is no crd file present, it will load the image only.

Rule 2: Never load a previously marked *image*. You will see the marks, but you cannot edit them, and the program has in fact no knowledge that there are marks on it. To the program, the image is just pixels. If you want to edit a previously worked-on image, you *must* reload the *original* image and have the .crd file present.

Example: Your original image is MyImage.jpg. You also have MyImage.crd. Assuming you’re in the directory in which Marker.jar resides, and that MyImage.jpg and MyImage.crd are also in that directory, run Marker like this:

java -cp Marker.jar Marker MyImage.jpg

It will find MyImage.crd, place the markers in the appropriate location, and you’re good to go.

Rule 3: This is not a piece of software that elegantly handles every exception or that lets you do anything with files. So you need to think ahead of time about a sensible system to organize your files.

Rule 4: Do not resize or edit the original image file if you ever want to go back to edit the marks.

Rule 5: You need to think ahead of time about the single-character codes you assign to the data, and you need to keep track of that in an independent document.

Ok, so you’ve loaded MyImage.jpg.

As you move the mouse over the image, you can type single alphanumeric characters (uppercase and lowercase letters, or digits). No clicking is required.

If you need to edit a mark, click on the edit button:

[pic]

Then click on the mark you want to edit. It will turn red:

[pic]

Type in the new value:

[pic]

(At first the new value will also be red, but it will go to black as you click elsewhere.)

When you’re done editing previous marks, click on the Mark button ...

[pic]

... and you’re back in marking mode.

Clicking Save will output the _marked.jpg file, the .out file, and the .crd file.

And remember: You can use Marker to count anything. Heck, you can use it to count stealth bombers:

[pic]

-----------------------

A

................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download