Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
otb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
273
Issues
273
List
Boards
Labels
Service Desk
Milestones
Merge Requests
8
Merge Requests
8
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Main Repositories
otb
Commits
c58738e2
Commit
c58738e2
authored
Nov 30, 2020
by
Cédric Traizet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
DEBUG: added more traces to ReflectanceToSurfaceReflectanceImageFilter
parent
3778390f
Pipeline
#6301
failed with stages
in 14 minutes and 36 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
7 deletions
+8
-7
Modules/Radiometry/OpticalCalibration/include/otbReflectanceToSurfaceReflectanceImageFilter.hxx
...include/otbReflectanceToSurfaceReflectanceImageFilter.hxx
+6
-6
Modules/Radiometry/OpticalCalibration/test/otbReflectanceToSurfaceReflectanceImageFilterTest.cxx
...est/otbReflectanceToSurfaceReflectanceImageFilterTest.cxx
+2
-1
No files found.
Modules/Radiometry/OpticalCalibration/include/otbReflectanceToSurfaceReflectanceImageFilter.hxx
View file @
c58738e2
...
...
@@ -97,15 +97,14 @@ void ReflectanceToSurfaceReflectanceImageFilter<TInputImage, TOutputImage>::Upda
}
const
auto
&
metadata
=
this
->
GetInput
()
->
GetImageMetadata
();
std
::
cout
<<
"Debug: UpdateAtmosphericRadiativeTerms "
<<
metadata
<<
std
::
endl
;
//
std::cout << "Debug: UpdateAtmosphericRadiativeTerms " << metadata << std::endl;
if
(
m_AtmoCorrectionParameters
->
GetAeronetFileName
()
!=
""
)
{
m_AtmoCorrectionParameters
->
UpdateAeronetData
(
metadata
[
MDTime
::
AcquisitionDate
].
GetYear
(),
metadata
[
MDTime
::
AcquisitionDate
].
GetHour
(),
metadata
[
MDTime
::
AcquisitionDate
].
GetMinute
());
}
std
::
cout
<<
metadata
[
MDTime
::
AcquisitionDate
].
GetYear
()
<<
" "
<<
metadata
[
MDTime
::
AcquisitionDate
].
GetMonth
()
<<
" "
<<
metadata
[
MDTime
::
AcquisitionDate
].
GetDay
()
<<
" "
<<
metadata
[
MDTime
::
AcquisitionDate
].
GetHour
()
<<
" "
<<
metadata
[
MDTime
::
AcquisitionDate
].
GetMinute
()
<<
std
::
endl
;
// Acquisition parameters
if
(
!
m_IsSetAcquiCorrectionParameters
)
// Get info from image metadata
{
...
...
@@ -137,7 +136,7 @@ std::cout << metadata[MDTime::AcquisitionDate].GetYear() << " " << metadata[MDTi
filterFunction
->
SetMaxSpectralValue
(
axis
.
Origin
+
axis
.
Spacing
*
axis
.
Size
);
filterFunction
->
SetUserStep
(
axis
.
Spacing
);
spectralSensitivity
->
PushBack
(
filterFunction
);
std
::
cout
<<
band
[
MDStr
::
BandName
]
<<
" "
<<
filterFunction
<<
std
::
endl
;
//std::cout
<< filterFunction << std::endl;
}
m_AcquiCorrectionParameters
->
SetWavelengthSpectralBand
(
spectralSensitivity
);
...
...
@@ -145,7 +144,8 @@ std::cout << metadata[MDTime::AcquisitionDate].GetYear() << " " << metadata[MDTi
else
{
otbMsgDevMacro
(
<<
"use dummy filter"
);
auto
spectralDummy
=
AcquiCorrectionParametersType
::
InternalWavelengthSpectralBandVectorType
::
New
();
WavelengthSpectralBandVectorType
spectralDummy
;
spectralDummy
->
Clear
();
for
(
unsigned
int
i
=
0
;
i
<
this
->
GetInput
()
->
GetNumberOfComponentsPerPixel
();
++
i
)
{
spectralDummy
->
PushBack
(
FilterFunctionValuesType
::
New
());
...
...
@@ -167,7 +167,7 @@ void ReflectanceToSurfaceReflectanceImageFilter<TInputImage, TOutputImage>::Upda
{
itkExceptionMacro
(
<<
"Input must be set before updating the functors"
);
}
std
::
cout
<<
"Update functor "
<<
this
->
GetInput
()
->
GetImageMetadata
()
<<
std
::
endl
;
this
->
GetFunctorVector
().
clear
();
for
(
unsigned
int
i
=
0
;
i
<
this
->
GetInput
()
->
GetNumberOfComponentsPerPixel
();
++
i
)
...
...
Modules/Radiometry/OpticalCalibration/test/otbReflectanceToSurfaceReflectanceImageFilterTest.cxx
View file @
c58738e2
...
...
@@ -114,6 +114,7 @@ int otbReflectanceToSurfaceReflectanceImageFilterTest2(int itkNotUsed(argc), cha
paramAtmo
->
SetAerosolOptical
(
static_cast
<
double
>
(
atof
(
argv
[
7
])));
ReaderType
::
Pointer
reader
=
ReaderType
::
New
();
WriterType
::
Pointer
writer
=
WriterType
::
New
();
reader
->
SetFileName
(
inputFileName
);
...
...
@@ -128,7 +129,7 @@ int otbReflectanceToSurfaceReflectanceImageFilterTest2(int itkNotUsed(argc), cha
writer
->
SetInput
(
filter
->
GetOutput
());
writer
->
Update
();
std
::
cout
<<
"PRINT FILTER"
<<
filter
<<
std
::
endl
;
/*filter->GenerateParameters();
otb::AtmosphericRadiativeTerms::Pointer terms = filter->GetAtmosphericRadiativeTerms();
...
...
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