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
98b0dee4
Commit
98b0dee4
authored
Jun 26, 2017
by
Andrey Filippov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
more on tile assignments
parent
42bc2c68
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
511 additions
and
44 deletions
+511
-44
EyesisCorrectionParameters.java
src/main/java/EyesisCorrectionParameters.java
+144
-2
TileAssignment.java
src/main/java/TileAssignment.java
+325
-39
TileProcessor.java
src/main/java/TileProcessor.java
+41
-2
TileSurface.java
src/main/java/TileSurface.java
+1
-1
No files found.
src/main/java/EyesisCorrectionParameters.java
View file @
98b0dee4
This diff is collapsed.
Click to expand it.
src/main/java/TileAssignment.java
View file @
98b0dee4
This diff is collapsed.
Click to expand it.
src/main/java/TileProcessor.java
View file @
98b0dee4
...
...
@@ -3494,14 +3494,53 @@ public class TileProcessor {
tile_assignments
);
// final int [][][] tileAssignments)
int
[][]
tile_layers_surf
=
ta
.
imgToSurf
(
tile_layers
);
ta
.
showTileCost
(
tile_layers_surf
);
ta
.
showTileCosts
(
tile_layers_surf
);
if
(
debugLevel
>
-
1
)
{
double
[][]
dbg_tls
=
new
double
[
tile_layers_surf
.
length
][];
for
(
int
ml
=
0
;
ml
<
tile_layers_surf
.
length
;
ml
++)
if
(
tile_layers_surf
[
ml
]
!=
null
){
dbg_tls
[
ml
]
=
new
double
[
tile_layers_surf
[
ml
].
length
];
for
(
int
i
=
0
;
i
<
tile_layers_surf
[
ml
].
length
;
i
++){
dbg_tls
[
ml
][
i
]
=
tile_layers_surf
[
ml
][
i
];
}
}
(
new
showDoubleFloatArrays
()).
showArrays
(
dbg_tls
,
ta
.
getSurfTilesX
(),
ta
.
getSurfTilesY
(),
true
,
"tile_layers_surf"
);
}
ta
.
showTileCost
(
"before_"
,
tile_layers_surf
);
ta
.
showTileCosts
(
"before_"
,
tile_layers_surf
);
TileAssignment
.
TACosts
[]
ta_stats
=
ta
.
statTileCosts
(
tile_layers_surf
);
for
(
int
i
=
0
;
i
<
ta_stats
.
length
;
i
++){
System
.
out
.
println
(
ta_stats
[
i
].
toString
());
}
ta
.
optimizeAssignment
(
clt_parameters
.
tsNoEdge
,
// final boolean noEdge,
tile_layers_surf
,
// final int [][] tileLayers,
2
,
// final int debugLevel,
clt_parameters
.
tileX
,
clt_parameters
.
tileY
);
if
(
debugLevel
>
-
1
)
{
double
[][]
dbg_tls
=
new
double
[
tile_layers_surf
.
length
][];
for
(
int
ml
=
0
;
ml
<
tile_layers_surf
.
length
;
ml
++)
if
(
tile_layers_surf
[
ml
]
!=
null
){
dbg_tls
[
ml
]
=
new
double
[
tile_layers_surf
[
ml
].
length
];
for
(
int
i
=
0
;
i
<
tile_layers_surf
[
ml
].
length
;
i
++){
dbg_tls
[
ml
][
i
]
=
tile_layers_surf
[
ml
][
i
];
}
}
(
new
showDoubleFloatArrays
()).
showArrays
(
dbg_tls
,
ta
.
getSurfTilesX
(),
ta
.
getSurfTilesY
(),
true
,
"optimized_tile_layers_surf"
);
}
ta
.
showTileCost
(
"after_"
,
tile_layers_surf
);
ta
.
showTileCosts
(
"after_"
,
tile_layers_surf
);
ta_stats
=
ta
.
statTileCosts
(
tile_layers_surf
);
System
.
out
.
println
(
"Optimized:"
);
for
(
int
i
=
0
;
i
<
ta_stats
.
length
;
i
++){
System
.
out
.
println
(
ta_stats
[
i
].
toString
());
}
tile_layers
=
ta
.
surfToImg
(
tile_layers_surf
);
//==============
tileSurface
.
setTileLayers
(
tile_layers
);
...
...
src/main/java/TileSurface.java
View file @
98b0dee4
...
...
@@ -2304,7 +2304,7 @@ public class TileSurface {
}
}
}
if
((
alts
.
size
()
>
1
)
||
(
num_agree
<
min_agree
)){
if
((
(
alts
.
size
()
>
1
)
||
(
num_agree
<
min_agree
))
&&
(
consensus
[
ml
][
nTile
]
>
0
)){
consensus
[
ml
][
nTile
]
=
0
;
// not assigned
}
if
(!
alts
.
isEmpty
()){
...
...
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