|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectSeg2Dgel.Sg2glb
Seg2Dgel.Sg2bkg
public class Sg2bkg
Class Sg2bkg computes background density of the input gel image for the 2D gel spot segmenter. Background is estimated using a zonal notch filter. First a 'rest of' image is computed as the original image less the segmented spots with the spots having density value 0. Then the zonal notch filter is computed over the entire image by moving an averaging window over the image in a raster, 1 pixel at a time where the mean density is computing in the averaging window at each point not including the 0 values. This background image is used to estimate the background for each spot by using it as a lookup table for the centroids of each spot.
This code was derived and refactored from GELLAB-II sg2gii C language files.
This work was produced by Peter Lemkin of the National Cancer Institute, an agency of the United States Government. As a work of the United States Government there is no associated copyright. It is offered as open source software under the Mozilla Public License (version 1.1) subject to the limitations noted in the accompanying LEGAL file. This notice must be included with the code. The Open2Dprot Mozilla and Legal files are available on http://Open2Dprot.sourceforge.net/.
| Field Summary | |
|---|---|
static int[] |
colsum
|
static int |
maxBkgrdTot
Max background computed over zonal notch background filter |
static int |
minBkgrdTot
Min background computed over zonal notch background filter |
static int[] |
nbrcolumnccs
|
| Constructor Summary | |
|---|---|
Sg2bkg()
Sg2bkg() - Constructor |
|
| Method Summary | |
|---|---|
void |
calcBackground(boolean useBkgdAndIsolatedPixelFlag)
calcBackground() - compute the notch filtered picture in pix6 using a window size of nBkgrdSize (global variable). |
static int |
mapXedge(int x,
int cwx1,
int cwx2)
mapXedge() - map x coordinate in the range [cwx1:cwx2]. |
static int |
mapYedge(int y,
int cwy1,
int cwy2)
mapYedge() - map y coordinate in the range [cwy1:cwy2]. |
void |
rowaddBkgd(int yline)
rowaddBkgd() - Read in line yLine, then add a nBkgrdSize X 1 subrow to each element of the sum in lineSum[cwx1:cwx2]. |
void |
rowaddBkgdAndIsolated(int yline)
rowaddBkgdAndIsolated() - Read in line yLine, then add a nBkgrdSize X 1 subrow to each element of the sum in lineSum[cwx1:cwx2]. |
void |
rowsubBkgd(int yline)
rowsubBkgd() - Read in line yLine, then subtract a nBkgrdSize X 1 subrow to each element of the sum in lineSum[cwx1:cwx2]. |
void |
rowsubBkgdAndIsolated(int yline)
rowsubBkgdAndIsolated() - Read in line yLine, then subtract a nBkgrdSize X 1 subrow to each element of the sum in lineSum[cwx1:cwx2]. |
| Methods inherited from class Seg2Dgel.Sg2glb |
|---|
get2D, get2D, getPixLineBuf, getPixLineBuf, initGlb, isDBwindow, isDBwindow, put2Dbuf, resetGlb, set2D, set2D, setPixLineBuf, setPixLineBuf, showReportStatus |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static int[] colsum
public static int[] nbrcolumnccs
public static int maxBkgrdTot
public static int minBkgrdTot
| Constructor Detail |
|---|
public Sg2bkg()
| Method Detail |
|---|
public void rowaddBkgd(int yline)
public void rowsubBkgd(int yline)
public void rowaddBkgdAndIsolated(int yline)
public void rowsubBkgdAndIsolated(int yline)
public void calcBackground(boolean useBkgdAndIsolatedPixelFlag)
useBkgdAndIsolatedPixelFlag - to define background as a
pixel as either BKGRD_CODE or ISOLATED_PIXEL_CODE
otherwise it is just BKGRD_CODE.
public static final int mapXedge(int x,
int cwx1,
int cwx2)
x - of pixelcwx1 - is lower boundcwx2 - is upper bound
public static final int mapYedge(int y,
int cwy1,
int cwy2)
y - of pixelcwy1 - is lower boundcwy2 - is upper bound
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||