Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
imagej-elphel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
3
Issues
3
List
Board
Labels
Milestones
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Elphel
imagej-elphel
Commits
3b27965b
Commit
3b27965b
authored
Apr 23, 2017
by
Andrey Filippov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
initial extraction of predefined planes
parent
5fc78264
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
105 additions
and
181 deletions
+105
-181
CLTPass3d.java
src/main/java/CLTPass3d.java
+6
-44
SuperTiles.java
src/main/java/SuperTiles.java
+82
-109
TilePlanes.java
src/main/java/TilePlanes.java
+0
-11
TileProcessor.java
src/main/java/TileProcessor.java
+17
-17
No files found.
src/main/java/CLTPass3d.java
View file @
3b27965b
...
...
@@ -69,7 +69,6 @@ public class CLTPass3d{
{
return
this
.
tileProcessor
;
}
public
void
updateSelection
(){
// add updating border tiles?
int
tilesX
=
tileProcessor
.
getTilesX
();
int
tilesY
=
tileProcessor
.
getTilesY
();
...
...
@@ -558,6 +557,9 @@ public class CLTPass3d{
return
this
.
superTiles
;
}
public
double
[]
showDisparityHistogram
(
double
[][][][]
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
boolean
[][]
tile_sel
,
// null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
boolean
smplMode
,
// = true; // Use sample mode (false - regular tile mode)
int
smplSide
,
// = 2; // Sample size (side of a square)
int
smplNum
,
// = 3; // Number after removing worst
...
...
@@ -568,6 +570,9 @@ public class CLTPass3d{
return
null
;
}
return
this
.
superTiles
.
showDisparityHistogram
(
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
tile_sel
,
// null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
smplMode
,
// = true; // Use sample mode (false - regular tile mode)
smplSide
,
// = 2; // Sample size (side of a square)
smplNum
,
// = 3; // Number after removing worst
...
...
@@ -575,49 +580,6 @@ public class CLTPass3d{
measSel
);
}
public
double
[]
showDisparityHistogram
()
{
if
(
this
.
superTiles
==
null
){
return
null
;
}
return
this
.
superTiles
.
showDisparityHistogram
();
}
public
double
[]
showDisparityHistogram
(
double
[][]
dispHist
)
{
if
(
this
.
superTiles
==
null
){
return
null
;
}
return
this
.
superTiles
.
showDisparityHistogram
(
dispHist
);
}
public
int
showDisparityHistogramWidth
()
{
return
this
.
superTiles
.
showDisparityHistogramWidth
();
}
public
double
[][][]
getMaxMinMax
(){
if
(
this
.
superTiles
==
null
){
return
null
;
}
return
superTiles
.
getMaxMinMax
();
}
public
double
[]
showMaxMinMax
(){
if
(
this
.
superTiles
==
null
){
return
null
;
}
return
this
.
superTiles
.
showMaxMinMax
();
}
public
int
getNumBins
(){
if
(
this
.
superTiles
==
null
){
return
0
;
}
return
superTiles
.
numBins
;
}
public
double
[]
getSuperTileStrength
()
{
if
(
this
.
superTiles
==
null
){
...
...
src/main/java/SuperTiles.java
View file @
3b27965b
...
...
@@ -154,6 +154,8 @@ public class SuperTiles{
cltPass3d
.
getSelected
());
// boolean [] selection) // may be null
getDisparityHistograms
(
null
,
// double [] world_plane, // tilt equi-disparity planes to match real world planes (usually horizontal (or null)
null
,
// boolean [][] tile_sel, // null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
smplMode
,
// final boolean smplMode, // = true; // Use sample mode (false - regular tile mode)
smplSide
,
// final int smplSide, // = 2; // Sample size (side of a square)
smplNum
,
// final int smplNum, // = 3; // Number after removing worst
...
...
@@ -345,83 +347,15 @@ public class SuperTiles{
System
.
out
.
println
(
"getLapWeights: sum = "
+
s
);
return
lapWeight
;
}
/*
public double [][] getDisparityHistograms(
final int measSel) // bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
{
if (this.disparityHistograms != null) return this.disparityHistograms;
// final double step_disparity = step_near; // TODO: implement
final int tilesX = tileProcessor.getTilesX();
final int tilesY = tileProcessor.getTilesY();
final int superTileSize = tileProcessor.superTileSize;
final int stilesX = (tilesX + superTileSize -1)/superTileSize;
final int stilesY = (tilesY + superTileSize -1)/superTileSize;
final int nStiles = stilesX * stilesY;
final double [][] dispHist = new double [nStiles][]; // now it will be sparse
final double [] strengthHist = new double [nStiles];
final Thread[] threads = ImageDtt.newThreadArray(tileProcessor.threadsMax);
final AtomicInteger ai = new AtomicInteger(0);
for (int ithread = 0; ithread < threads.length; ithread++) {
threads[ithread] = new Thread() {
public void run() {
for (int nsTile = ai.getAndIncrement(); nsTile < nStiles; nsTile = ai.getAndIncrement()) {
int stileY = nsTile / stilesX;
int stileX = nsTile % stilesX;
double sw = 0.0; // sum weights
double [] hist = new double [numBins];
for (int nl = 0; nl < measuredLayers.getNumLayers(); nl ++) {
if ((measSel & (1 << nl)) != 0) {
double [][] disp_strength = measuredLayers.getDisparityStrength(
nl, // int num_layer,
stileX, // int stX,
stileY, // int stY,
null, // boolean [] sel_in,
strength_floor, // double strength_floor,
strength_pow, // double strength_pow,
true); // boolean null_if_none);
if (disp_strength != null) {
for (int indx = 0; indx < disp_strength[1].length; indx++) {
double w = disp_strength[1][indx];
if ( w > 0.0){
double d = disp_strength[0][indx];
int bin = disparityToBin(d);
if ((bin >= 0) && (bin < numBins)){ // maybe collect below min and above max somewhere?
hist[bin] += w; // +1]
sw +=w;
}
}
}
}
}
}
strengthHist[nsTile] = sw / superTileSize / superTileSize; // average strength per tile in the super-tile
if (sw > 0){
for (int i = 0; i<numBins; i++){
hist[i] /= sw;
}
dispHist[nsTile] = hist;
} else {
dispHist[nsTile] = null;
}
}
}
};
}
ImageDtt.startAndJoin(threads);
this.disparityHistograms = dispHist;
this.stStrength = strengthHist;
if (this.stBlurSigma > 0.0) {
blurDisparityHistogram(0); // debugLevel);
}
return this.disparityHistograms; // dispHist;
}
*/
public
double
[][]
getDisparityHistograms
(
final
boolean
smplMode
,
// = true; // Use sample mode (false - regular tile mode)
final
int
smplSide
,
// = 2; // Sample size (side of a square)
final
int
smplNum
,
// = 3; // Number after removing worst
final
double
smplRms
,
// = 0.1; // Maximal RMS of the remaining tiles in a sample
final
int
measSel
)
//
final
double
[][][][]
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
final
boolean
[][]
tile_sel
,
// null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
final
boolean
smplMode
,
// = true; // Use sample mode (false - regular tile mode)
final
int
smplSide
,
// = 2; // Sample size (side of a square)
final
int
smplNum
,
// = 3; // Number after removing worst
final
double
smplRms
,
// = 0.1; // Maximal RMS of the remaining tiles in a sample
final
int
measSel
)
//
{
if
((
this
.
disparityHistograms
!=
null
)
&&
(
smplMode
==
this
.
smplMode
)
&&
...
...
@@ -439,7 +373,7 @@ public class SuperTiles{
final
int
tilesX
=
tileProcessor
.
getTilesX
();
final
int
tilesY
=
tileProcessor
.
getTilesY
();
final
int
superTileSize
=
tileProcessor
.
superTileSize
;
final
int
superTileSize
=
tileProcessor
.
getSuperTileSize
()
;
final
int
stilesX
=
(
tilesX
+
superTileSize
-
1
)/
superTileSize
;
final
int
stilesY
=
(
tilesY
+
superTileSize
-
1
)/
superTileSize
;
final
int
nStiles
=
stilesX
*
stilesY
;
...
...
@@ -447,38 +381,48 @@ public class SuperTiles{
final
double
[]
strengthHist
=
new
double
[
nStiles
];
final
Thread
[]
threads
=
ImageDtt
.
newThreadArray
(
tileProcessor
.
threadsMax
);
final
AtomicInteger
ai
=
new
AtomicInteger
(
0
);
final
TilePlanes
tpl
=
new
TilePlanes
(
tileProcessor
.
getTileSize
(),
superTileSize
);
for
(
int
ithread
=
0
;
ithread
<
threads
.
length
;
ithread
++)
{
threads
[
ithread
]
=
new
Thread
()
{
public
void
run
()
{
for
(
int
nsTile
=
ai
.
getAndIncrement
();
nsTile
<
nStiles
;
nsTile
=
ai
.
getAndIncrement
())
{
int
stileY
=
nsTile
/
stilesX
;
int
stileX
=
nsTile
%
stilesX
;
int
stileX
=
nsTile
%
stilesX
;
double
sw
=
0.0
;
// sum weights
double
[]
hist
=
new
double
[
numBins
];
// double [][][] disp_strength = new double [measuredLayers.getNumLayers()][][] ;
for
(
int
nl
=
0
;
nl
<
measuredLayers
.
getNumLayers
();
nl
++)
{
if
((
measSel
&
(
1
<<
nl
))
!=
0
)
{
if
((
(
measSel
&
(
1
<<
nl
))
!=
0
)
&&
((
tile_sel
==
null
)
||
((
tile_sel
[
nl
]
!=
null
)))
)
{
double
[][]
disp_strength
;
if
(
smplMode
)
{
disp_strength
=
measuredLayers
.
getDisparityStrength
(
nl
,
// int num_layer,
stileX
,
// int stX,
stileY
,
// int stY,
null
,
// boolean [] sel_in,
strength_floor
,
// double strength_floor,
strength_pow
,
// double strength_pow,
smplSide
,
// int smplSide, // = 2; // Sample size (side of a square)
smplNum
,
//int smplNum, // = 3; // Number after removing worst (should be >1)
smplRms
,
//double smplRms, // = 0.1; // Maximal RMS of the remaining tiles in a sample
true
);
// boolean null_if_none);
if
(
disparity_strength
==
null
)
{
if
(
smplMode
)
{
disp_strength
=
measuredLayers
.
getDisparityStrength
(
nl
,
// int num_layer,
stileX
,
// int stX,
stileY
,
// int stY,
(((
tile_sel
==
null
)
||
(
tile_sel
[
nl
].
length
==
0
))?
null
:
tile_sel
[
nl
]),
// boolean [] sel_in,
// null, // boolean [] sel_in,
strength_floor
,
// double strength_floor,
strength_pow
,
// double strength_pow,
smplSide
,
// int smplSide, // = 2; // Sample size (side of a square)
smplNum
,
//int smplNum, // = 3; // Number after removing worst (should be >1)
smplRms
,
//double smplRms, // = 0.1; // Maximal RMS of the remaining tiles in a sample
true
);
// boolean null_if_none);
}
else
{
disp_strength
=
measuredLayers
.
getDisparityStrength
(
nl
,
// int num_layer,
stileX
,
// int stX,
stileY
,
// int stY,
(((
tile_sel
==
null
)
||
(
tile_sel
[
nl
].
length
==
0
))?
null
:
tile_sel
[
nl
]),
// boolean [] sel_in,
// null, // boolean [] sel_in,
strength_floor
,
// double strength_floor,
strength_pow
,
// double strength_pow,
true
);
// boolean null_if_none);
}
}
else
{
disp_strength
=
measuredLayers
.
getDisparityStrength
(
nl
,
// int num_layer,
stileX
,
// int stX,
stileY
,
// int stY,
null
,
// boolean [] sel_in,
strength_floor
,
// double strength_floor,
strength_pow
,
// double strength_pow,
true
);
// boolean null_if_none);
disp_strength
=
disparity_strength
[
nsTile
][
nl
];
}
if
(
disp_strength
!=
null
)
{
for
(
int
indx
=
0
;
indx
<
disp_strength
[
1
].
length
;
indx
++)
{
...
...
@@ -547,9 +491,16 @@ public class SuperTiles{
}
// returns odd-length array of max/min (x, strength) pairs
public
double
[][][]
getMaxMinMax
(){
public
double
[][][]
getMaxMinMax
(
// final double [] world_plane, // tilt equi-disparity planes to match real world planes (usually horizontal (or null)
final
double
[][][][]
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
final
boolean
[][]
tile_sel
// null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
){
// first find all integer maximums, and if the top is flat - use the middle. If not flat - use 2-nd degree polynomial
if
(
disparityHistograms
==
null
)
getDisparityHistograms
(
// world_plane, // double [] world_plane, // tilt equi-disparity planes to match real world planes (usually horizontal (or null)
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
tile_sel
,
// boolean [][] tile_sel, // null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
this
.
smplMode
,
// final boolean smplMode, // = true; // Use sample mode (false - regular tile mode)
this
.
smplSide
,
// final int smplSide, // = 2; // Sample size (side of a square)
this
.
smplNum
,
// final int smplNum, // = 3; // Number after removing worst
...
...
@@ -685,6 +636,8 @@ public class SuperTiles{
{
if
(
disparityHistograms
==
null
){
getDisparityHistograms
(
null
,
// double [] world_plane, // tilt equi-disparity planes to match real world planes (usually horizontal (or null)
null
,
// boolean [][] tile_sel, // null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
this
.
smplMode
,
// final boolean smplMode, // = true; // Use sample mode (false - regular tile mode)
this
.
smplSide
,
// final int smplSide, // = 2; // Sample size (side of a square)
this
.
smplNum
,
// final int smplNum, // = 3; // Number after removing worst
...
...
@@ -696,6 +649,9 @@ public class SuperTiles{
public
double
[]
showDisparityHistogram
(
// double [] world_plane, // tilt equi-disparity planes to match real world planes (usually horizontal (or null)
final
double
[][][][]
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
boolean
[][]
tile_sel
,
// null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
boolean
smplMode
,
// = true; // Use sample mode (false - regular tile mode)
int
smplSide
,
// = 2; // Sample size (side of a square)
int
smplNum
,
// = 3; // Number after removing worst
...
...
@@ -703,6 +659,9 @@ public class SuperTiles{
int
measSel
)
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
{
getDisparityHistograms
(
// will recalculate if does not exist or some parameters changed
// world_plane, // double [] world_plane, // tilt equi-disparity planes to match real world planes (usually horizo
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or nullntal (or null)
tile_sel
,
// boolean [][] tile_sel, // null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
smplMode
,
// final boolean smplMode, // = true; // Use sample mode (false - regular tile mode)
smplSide
,
// final int smplSide, // = 2; // Sample size (side of a square)
smplNum
,
// final int smplNum, // = 3; // Number after removing worst
...
...
@@ -766,9 +725,24 @@ public class SuperTiles{
}
return
rslt
;
}
public
double
[]
showMaxMinMax
(){
if
(
maxMinMax
==
null
){
getMaxMinMax
();
// calculate and blur with the current settings, specified at instantiation
return
showMaxMinMax
(
// calculate and blur with the current settings, specified at instantiation
null
,
null
);
}
public
double
[]
showMaxMinMax
(
// double [] world_plane, // tilt equi-disparity planes to match real world planes (usually horizontal (or null)
double
[][][][]
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
boolean
[][]
tile_sel
// null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
){
if
(
maxMinMax
==
null
){
getMaxMinMax
(
// calculate and blur with the current settings, specified at instantiation
// world_plane, // tilt equi-disparity planes to match real world planes (usually horizontal (or null)
disparity_strength
,
// pre-calculated disparity/strength [per super-tile][per-measurement layer][2][tiles] or null
tile_sel
);
// null or per-measurement layer, per-tile selection. For each layer null - do not use, {} - use all
}
final
int
superTileSize
=
tileProcessor
.
superTileSize
;
...
...
@@ -1154,7 +1128,7 @@ public class SuperTiles{
final
double
plDispNorm
,
final
int
debugLevel
)
{
if
(
maxMinMax
==
null
)
getMaxMinMax
();
if
(
maxMinMax
==
null
)
getMaxMinMax
(
null
,
null
);
final
int
np_min
=
5
;
// minimal number of points to consider
final
int
tilesX
=
tileProcessor
.
getTilesX
();
final
int
tilesY
=
tileProcessor
.
getTilesY
();
...
...
@@ -1364,7 +1338,7 @@ public class SuperTiles{
final
int
dbg_X
,
final
int
dbg_Y
)
{
if
(
maxMinMax
==
null
)
getMaxMinMax
();
if
(
maxMinMax
==
null
)
getMaxMinMax
(
null
,
null
);
// final int np_min = 5; // minimal number of points to consider
final
int
tilesX
=
tileProcessor
.
getTilesX
();
final
int
tilesY
=
tileProcessor
.
getTilesY
();
...
...
@@ -1689,7 +1663,7 @@ public class SuperTiles{
final
int
dbg_X
,
final
int
dbg_Y
)
{
if
(
maxMinMax
==
null
)
getMaxMinMax
();
if
(
maxMinMax
==
null
)
getMaxMinMax
(
null
,
null
);
final
int
tilesX
=
tileProcessor
.
getTilesX
();
final
int
tilesY
=
tileProcessor
.
getTilesY
();
final
int
superTileSize
=
tileProcessor
.
getSuperTileSize
();
...
...
@@ -1739,7 +1713,7 @@ public class SuperTiles{
}
// if (maxMinMax == null)
getMaxMinMax
();
getMaxMinMax
(
null
,
null
);
for
(
int
ithread
=
0
;
ithread
<
threads
.
length
;
ithread
++)
{
threads
[
ithread
]
=
new
Thread
()
{
...
...
@@ -2082,7 +2056,7 @@ public class SuperTiles{
final
int
dbg_X
,
final
int
dbg_Y
)
{
if
(
maxMinMax
==
null
)
getMaxMinMax
(
);
if
(
maxMinMax
==
null
)
getMaxMinMax
(
null
,
null
);
// so far - no planes, no selection
final
int
tilesX
=
tileProcessor
.
getTilesX
();
final
int
tilesY
=
tileProcessor
.
getTilesY
();
final
int
superTileSize
=
tileProcessor
.
getSuperTileSize
();
...
...
@@ -2129,8 +2103,7 @@ public class SuperTiles{
showDoubleFloatArrays
sdfa_instance
=
new
showDoubleFloatArrays
();
sdfa_instance
.
showArrays
(
dbg_img
,
tileProcessor
.
getTilesX
(),
tileProcessor
.
getTilesY
(),
true
,
"measuredLayers"
,
titles
);
}
// if (maxMinMax == null)
getMaxMinMax
();
getMaxMinMax
(
null
,
null
);
for
(
int
ithread
=
0
;
ithread
<
threads
.
length
;
ithread
++)
{
threads
[
ithread
]
=
new
Thread
()
{
...
...
src/main/java/TilePlanes.java
View file @
3b27965b
...
...
@@ -684,7 +684,6 @@ public class TilePlanes {
// make a plane and find the worst (largest disparity difference) tile
// z = -(x*Vx + y*Vy)/Vz
// double [][][] disp_str = new double [measuredSelection.length][][];
double
worst_d2
=
0.0
;
int
[]
worst_layer_index
=
{-
1
,-
1
};
double
[]
v
=
getVector
();
...
...
@@ -692,16 +691,6 @@ public class TilePlanes {
for
(
int
nl
=
0
;
nl
<
measuredSelection
.
length
;
nl
++){
if
(
measuredSelection
[
nl
]
!=
null
){
// already calculated, but not masked by selection!
/*
disp_str[nl] = measuredLayers.getDisparityStrength(
nl, // int num_layer,
sTileXY[0], // int stX,
sTileXY[1], // int stY,
measuredSelection[nl], // boolean [] sel_in,
strength_floor, //
measured_strength_pow, //
true); // boolean null_if_none)
*/
if
(
disp_str
[
nl
]
!=
null
)
{
for
(
int
indx
=
0
;
indx
<
disp_str
[
nl
][
0
].
length
;
indx
++){
double
w
=
disp_str
[
nl
][
1
][
indx
];
...
...
src/main/java/TileProcessor.java
View file @
3b27965b
...
...
@@ -2759,7 +2759,7 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
0
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
0
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
scan_prev
.
setSuperTiles
(
clt_parameters
.
stStepNear
,
// double step_disparity,
...
...
@@ -2775,11 +2775,11 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
1
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
1
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
dbg_hist
[
2
]
=
scan_prev
.
showMaxMinMax
();
dbg_hist
[
2
]
=
scan_prev
.
getSuperTiles
().
showMaxMinMax
();
int
hist_width0
=
scan_prev
.
showDisparityHistogramWidth
();
int
hist_width0
=
scan_prev
.
getSuperTiles
().
showDisparityHistogramWidth
();
int
hist_height0
=
dbg_hist
[
0
].
length
/
hist_width0
;
if
(
show_st
){
sdfa_instance
.
showArrays
(
dbg_hist
,
hist_width0
,
hist_height0
,
true
,
"disparity_supertiles_histograms"
,
dbg_st_titles
);
...
...
@@ -2973,7 +2973,7 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
0
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
0
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
scan_prev
.
setSuperTiles
(
clt_parameters
.
stStepNear
,
// double step_disparity,
clt_parameters
.
stStepFar
,
// double step_near,
...
...
@@ -2988,7 +2988,7 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
1
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
1
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
}
// SuperTiles st =
...
...
@@ -3007,13 +3007,13 @@ public class TileProcessor {
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
if
(
show_st
)
{
// otherwise only blured version is needed
dbg_hist
[
2
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
3
]
=
scan_prev
.
showMaxMinMax
();
dbg_hist
[
2
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
dbg_hist
[
3
]
=
scan_prev
.
getSuperTiles
().
showMaxMinMax
();
}
if
(
show_st
){
int
hist_width0
=
scan_prev
.
showDisparityHistogramWidth
();
int
hist_width0
=
scan_prev
.
getSuperTiles
().
showDisparityHistogramWidth
();
int
hist_height0
=
dbg_hist
[
0
].
length
/
hist_width0
;
showDoubleFloatArrays
sdfa_instance
=
new
showDoubleFloatArrays
();
// just for debugging?
sdfa_instance
.
showArrays
(
dbg_hist
,
hist_width0
,
hist_height0
,
true
,
"disparity_supertiles_histograms"
,
dbg_st_titles
);
...
...
@@ -3614,7 +3614,7 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
0
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
0
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
SuperTiles
st
=
scan_prev
.
setSuperTiles
(
clt_parameters
.
stStepNear
,
// double step_disparity,
...
...
@@ -3630,11 +3630,11 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
1
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
1
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
dbg_hist
[
2
]
=
scan_prev
.
showMaxMinMax
();
dbg_hist
[
2
]
=
scan_prev
.
getSuperTiles
().
showMaxMinMax
();
int
hist_width0
=
scan_prev
.
showDisparityHistogramWidth
();
int
hist_width0
=
scan_prev
.
getSuperTiles
().
showDisparityHistogramWidth
();
int
hist_height0
=
dbg_hist
[
0
].
length
/
hist_width0
;
if
(
show_st
){
...
...
@@ -4431,7 +4431,7 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
0
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
0
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
scan_prev
.
setSuperTiles
(
clt_parameters
.
stStepNear
,
// double step_disparity,
...
...
@@ -4447,12 +4447,12 @@ public class TileProcessor {
clt_parameters
.
stSmplNum
,
// Number after removing worst
clt_parameters
.
stSmplRms
,
// Maximal RMS of the remaining tiles in a sample
clt_parameters
.
stMeasSel
);
// bitmask of the selected measurements for supertiles : +1 - combo, +2 - quad +4 - hor +8 - vert
dbg_hist
[
1
]
=
scan_prev
.
showDisparityHistogram
();
dbg_hist
[
1
]
=
scan_prev
.
getSuperTiles
().
showDisparityHistogram
();
dbg_hist
[
2
]
=
scan_prev
.
showMaxMinMax
();
dbg_hist
[
2
]
=
scan_prev
.
getSuperTiles
().
showMaxMinMax
();
if
(
clt_parameters
.
stShow
){
int
hist_width0
=
scan_prev
.
showDisparityHistogramWidth
();
int
hist_width0
=
scan_prev
.
getSuperTiles
().
showDisparityHistogramWidth
();
int
hist_height0
=
dbg_hist
[
0
].
length
/
hist_width0
;
sdfa_instance
.
showArrays
(
dbg_hist
,
hist_width0
,
hist_height0
,
true
,
"disparity_supertiles_histograms"
,
dbg_st_titles
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment