Description Usage Arguments Value See Also Examples
Calculates a disparity map between two SAR records using window based zero normalized cross correlation (ZNCC).
1 2 3 | disparityMap(master, slave, window.size = 3, search.area.size = 7,
search.area.shift = c(0, 0), resample.slave = T, window.moving.step = 1,
run.parallel = F, cores = 4, log = F, log.file = "dispMapLog.txt")
|
master |
Object of the |
slave |
Object of the |
window.size |
Integer or vector of integers. Edge Length of quadratic window(s) to calculate |
search.area.size |
Integer. Edge Length of quadratic search area in slave image. |
search.area.shift |
Numeric vector. Pixels in x and y direction that the search area should be shifted. That is how a priori knowledge about disparity can be regarded. |
resample.slave |
Logical. Should the slave image be resampled to the aggregated master image? |
window.moving.step |
Integer. Step size to move windows in slave image. Default is 1. |
run.parallel |
Logical. Run algorithm on more than one cores? |
cores |
Integer. How many cores should be allocated? |
log |
Logical. Log output to text file? |
log.file |
Character. Log file address and name. |
Four dimensional array. The first and second dimension give rows and columns, respectively. The third and forth dimension gives disparities in x and y direction. The disparity is measured in pixel.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | data(kili)
master <- aggregate(master, 5)
disp.map <- disparityMap(master, slave, window.size=11, search.area.size=25)
disp.map.lon <- raster(disp.map[,,1])
extent(disp.map.lon) <- extent(master)
plot(disp.map.lon)
disp.map.lat <- raster(disp.map[,,2])
extent(disp.map.lat) <- extent(master)
plot(disp.map.lat)
disp.map.diagonal <- disp.map.lon
values(disp.map.diagonal) <- sqrt(disp.map.lat[]^2 + disp.map.lon[]^2)
plot(disp.map.diagonal)
# to run parallel register cores first, e.g.:
# library(doMC)
# registerDoMC(4)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.