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
ebc7ffad
Commit
ebc7ffad
authored
Dec 09, 2025
by
Andrey Filippov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Generating keyframe 16-images
parent
748d396b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
10 deletions
+37
-10
IntersceneMatchParameters.java
...lphel/imagej/tileprocessor/IntersceneMatchParameters.java
+15
-10
OpticalFlow.java
...ain/java/com/elphel/imagej/tileprocessor/OpticalFlow.java
+22
-0
No files found.
src/main/java/com/elphel/imagej/tileprocessor/IntersceneMatchParameters.java
View file @
ebc7ffad
...
@@ -307,9 +307,10 @@ public class IntersceneMatchParameters {
...
@@ -307,9 +307,10 @@ public class IntersceneMatchParameters {
public
boolean
reuse_video
=
false
;
// dry-run video generation, just reassemble video fragments (active if !generate_mapped)
public
boolean
reuse_video
=
false
;
// dry-run video generation, just reassemble video fragments (active if !generate_mapped)
public
boolean
save_mapped_color
=
false
;
// may be not needed when using AVI
public
boolean
save_mapped_color
=
false
;
// may be not needed when using AVI
public
boolean
save_mapped_mono
=
true
;
// may be not needed when using AVI
public
boolean
save_mapped_mono
=
true
;
// may be not needed when using AVI
public
boolean
generate_keyframes
=
false
;
// generate all sensor images for keyframes, matching DSI_MAIN, not motion blur corrected.
public
boolean
generate_raw
=
false
;
public
boolean
generate_raw
=
false
;
public
boolean
generate_inf
=
false
;
public
boolean
generate_inf
=
false
;
public
boolean
generate_fg
=
true
;
public
boolean
generate_fg
=
true
;
public
boolean
generate_bg
=
false
;
public
boolean
generate_bg
=
false
;
public
boolean
generate_stereo
=
false
;
// applies to all stereobases, including 0
public
boolean
generate_stereo
=
false
;
// applies to all stereobases, including 0
...
@@ -1697,8 +1698,8 @@ min_str_neib_fpn 0.35
...
@@ -1697,8 +1698,8 @@ min_str_neib_fpn 0.35
"Show generated scene sequences in (pseudo) color mode. Disabled in batch mode"
);
"Show generated scene sequences in (pseudo) color mode. Disabled in batch mode"
);
gd
.
addCheckbox
(
"Show scene sequences in monochrome"
,
this
.
show_mapped_mono
,
gd
.
addCheckbox
(
"Show scene sequences in monochrome"
,
this
.
show_mapped_mono
,
"Show generated scene sequences in monochrome mode. May use Unsharp Mask. Disabled in batch mode."
);
"Show generated scene sequences in monochrome mode. May use Unsharp Mask. Disabled in batch mode."
);
gd
.
addCheckbox
(
"Save all-sensor keyframe images"
,
this
.
generate_keyframes
,
"Generate all sensor images for keyframes, matching DSI_MAIN, not motion blur corrected."
);
gd
.
addCheckbox
(
"Generate RAW images"
,
this
.
generate_raw
,
gd
.
addCheckbox
(
"Generate RAW images"
,
this
.
generate_raw
,
"Raw images from single (top) camera using original view - just after aberration correction and aligning sensors ."
);
"Raw images from single (top) camera using original view - just after aberration correction and aligning sensors ."
);
gd
.
addCheckbox
(
"Generate INF images"
,
this
.
generate_inf
,
gd
.
addCheckbox
(
"Generate INF images"
,
this
.
generate_inf
,
...
@@ -3556,6 +3557,7 @@ min_str_neib_fpn 0.35
...
@@ -3556,6 +3557,7 @@ min_str_neib_fpn 0.35
this
.
gen_avi_mono
=
gd
.
getNextBoolean
();
// as video
this
.
gen_avi_mono
=
gd
.
getNextBoolean
();
// as video
this
.
show_mapped_color
=
gd
.
getNextBoolean
();
this
.
show_mapped_color
=
gd
.
getNextBoolean
();
this
.
show_mapped_mono
=
gd
.
getNextBoolean
();
this
.
show_mapped_mono
=
gd
.
getNextBoolean
();
this
.
generate_keyframes
=
gd
.
getNextBoolean
();
this
.
generate_raw
=
gd
.
getNextBoolean
();
this
.
generate_raw
=
gd
.
getNextBoolean
();
this
.
generate_inf
=
gd
.
getNextBoolean
();
this
.
generate_inf
=
gd
.
getNextBoolean
();
this
.
generate_fg
=
gd
.
getNextBoolean
();
this
.
generate_fg
=
gd
.
getNextBoolean
();
...
@@ -4715,11 +4717,12 @@ min_str_neib_fpn 0.35
...
@@ -4715,11 +4717,12 @@ min_str_neib_fpn 0.35
properties
.
setProperty
(
prefix
+
"reuse_video"
,
this
.
reuse_video
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"reuse_video"
,
this
.
reuse_video
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"save_mapped_color"
,
this
.
save_mapped_color
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"save_mapped_color"
,
this
.
save_mapped_color
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"save_mapped_mono"
,
this
.
save_mapped_mono
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"save_mapped_mono"
,
this
.
save_mapped_mono
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"gen_avi_color"
,
this
.
gen_avi_color
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"gen_avi_color"
,
this
.
gen_avi_color
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"gen_avi_mono"
,
this
.
gen_avi_mono
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"gen_avi_mono"
,
this
.
gen_avi_mono
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"show_mapped_color"
,
this
.
show_mapped_color
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"show_mapped_color"
,
this
.
show_mapped_color
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"show_mapped_mono"
,
this
.
show_mapped_mono
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"show_mapped_mono"
,
this
.
show_mapped_mono
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"generate_keyframes"
,
this
.
generate_keyframes
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"generate_raw"
,
this
.
generate_raw
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"generate_raw"
,
this
.
generate_raw
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"generate_inf"
,
this
.
generate_inf
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"generate_inf"
,
this
.
generate_inf
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"generate_fg"
,
this
.
generate_fg
+
""
);
// boolean
properties
.
setProperty
(
prefix
+
"generate_fg"
,
this
.
generate_fg
+
""
);
// boolean
...
@@ -5828,9 +5831,10 @@ min_str_neib_fpn 0.35
...
@@ -5828,9 +5831,10 @@ min_str_neib_fpn 0.35
if
(
properties
.
getProperty
(
prefix
+
"save_mapped_mono"
)!=
null
)
this
.
save_mapped_mono
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"save_mapped_mono"
));
if
(
properties
.
getProperty
(
prefix
+
"save_mapped_mono"
)!=
null
)
this
.
save_mapped_mono
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"save_mapped_mono"
));
if
(
properties
.
getProperty
(
prefix
+
"gen_avi_color"
)!=
null
)
this
.
gen_avi_color
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"gen_avi_color"
));
if
(
properties
.
getProperty
(
prefix
+
"gen_avi_color"
)!=
null
)
this
.
gen_avi_color
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"gen_avi_color"
));
if
(
properties
.
getProperty
(
prefix
+
"gen_avi_mono"
)!=
null
)
this
.
gen_avi_mono
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"gen_avi_mono"
));
if
(
properties
.
getProperty
(
prefix
+
"gen_avi_mono"
)!=
null
)
this
.
gen_avi_mono
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"gen_avi_mono"
));
if
(
properties
.
getProperty
(
prefix
+
"show_mapped_color"
)!=
null
)
this
.
show_mapped_color
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"show_mapped_color"
));
if
(
properties
.
getProperty
(
prefix
+
"show_mapped_color"
)!=
null
)
this
.
show_mapped_color
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"show_mapped_color"
));
if
(
properties
.
getProperty
(
prefix
+
"show_mapped_mono"
)!=
null
)
this
.
show_mapped_mono
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"show_mapped_mono"
));
if
(
properties
.
getProperty
(
prefix
+
"show_mapped_mono"
)!=
null
)
this
.
show_mapped_mono
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"show_mapped_mono"
));
if
(
properties
.
getProperty
(
prefix
+
"generate_keyframes"
)!=
null
)
this
.
generate_keyframes
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"generate_keyframes"
));
if
(
properties
.
getProperty
(
prefix
+
"generate_raw"
)!=
null
)
this
.
generate_raw
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"generate_raw"
));
if
(
properties
.
getProperty
(
prefix
+
"generate_raw"
)!=
null
)
this
.
generate_raw
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"generate_raw"
));
if
(
properties
.
getProperty
(
prefix
+
"generate_inf"
)!=
null
)
this
.
generate_inf
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"generate_inf"
));
if
(
properties
.
getProperty
(
prefix
+
"generate_inf"
)!=
null
)
this
.
generate_inf
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"generate_inf"
));
if
(
properties
.
getProperty
(
prefix
+
"generate_fg"
)!=
null
)
this
.
generate_fg
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"generate_fg"
));
if
(
properties
.
getProperty
(
prefix
+
"generate_fg"
)!=
null
)
this
.
generate_fg
=
Boolean
.
parseBoolean
(
properties
.
getProperty
(
prefix
+
"generate_fg"
));
...
@@ -6968,6 +6972,7 @@ min_str_neib_fpn 0.35
...
@@ -6968,6 +6972,7 @@ min_str_neib_fpn 0.35
imp
.
show_mapped_color
=
this
.
show_mapped_color
;
imp
.
show_mapped_color
=
this
.
show_mapped_color
;
imp
.
show_mapped_mono
=
this
.
show_mapped_mono
;
imp
.
show_mapped_mono
=
this
.
show_mapped_mono
;
imp
.
generate_keyframes
=
this
.
generate_keyframes
;
imp
.
generate_raw
=
this
.
generate_raw
;
imp
.
generate_raw
=
this
.
generate_raw
;
imp
.
generate_inf
=
this
.
generate_inf
;
imp
.
generate_inf
=
this
.
generate_inf
;
imp
.
generate_fg
=
this
.
generate_fg
;
imp
.
generate_fg
=
this
.
generate_fg
;
...
...
src/main/java/com/elphel/imagej/tileprocessor/OpticalFlow.java
View file @
ebc7ffad
...
@@ -4151,6 +4151,8 @@ public class OpticalFlow {
...
@@ -4151,6 +4151,8 @@ public class OpticalFlow {
double
disp_scan_step
=
clt_parameters
.
disp_scan_step
;
double
disp_scan_step
=
clt_parameters
.
disp_scan_step
;
int
disp_scan_count
=
clt_parameters
.
disp_scan_count
;
int
disp_scan_count
=
clt_parameters
.
disp_scan_count
;
boolean
no_bg_generate
=
!
clt_parameters
.
generate_bg
;
boolean
no_bg_generate
=
!
clt_parameters
.
generate_bg
;
boolean
generate_keyframes
=
clt_parameters
.
imp
.
generate_keyframes
;
boolean
no_lma
=
false
;
boolean
no_lma
=
false
;
if
(
fast
)
{
if
(
fast
)
{
no_lma
=
true
;
no_lma
=
true
;
...
@@ -4230,6 +4232,26 @@ public class OpticalFlow {
...
@@ -4230,6 +4232,26 @@ public class OpticalFlow {
}
}
boolean
ran_photo_each
=
false
;
boolean
ran_photo_each
=
false
;
quadCLT_ref
.
tp
.
resetCLTPasses
();
quadCLT_ref
.
tp
.
resetCLTPasses
();
if
(
generate_keyframes
)
{
int
tile_size
=
quadCLT_ref
.
getTileSize
();
int
[]
wh
=
{
quadCLT_ref
.
getTilesX
()*
tile_size
,
quadCLT_ref
.
getTilesY
()*
tile_size
};
double
[][]
keyframe16
=
quadCLT_ref
.
renderDoubleFromTDMono
(
-
1
,
// all sensors // final int sensor_mask,
wh
,
// null, // int [] wh,
false
);
// boolean use_reference
String
[]
titles16
=
new
String
[
keyframe16
.
length
];
for
(
int
i
=
0
;
i
<
titles16
.
length
;
i
++)
{
titles16
[
i
]
=
"port_"
+
i
;
}
quadCLT_ref
.
saveDoubleArrayInModelDirectory
(
"-KEYFRAME-SENSORS"
,
// String suffix,
titles16
,
// String [] labels, // or null
keyframe16
,
// double [][] data,
wh
[
0
],
// int width,
wh
[
1
]);
// int height)
}
// perform photometric here, after first DSI
// perform photometric here, after first DSI
if
(!
skip_photo
&&
(
photo_each
&&
(!
quadCLT_ref
.
isPhotometricThis
()
||
!
batch_mode
)))
{
if
(!
skip_photo
&&
(
photo_each
&&
(!
quadCLT_ref
.
isPhotometricThis
()
||
!
batch_mode
)))
{
// if (debugLevel > -3) {
// if (debugLevel > -3) {
...
...
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