Commit 38b2d27c authored by Cédric Traizet's avatar Cédric Traizet
Browse files

DOC: add documentation for S1ThermalNoiseLookupData

parent 3fab301c
Pipeline #7261 failed with stages
in 83 minutes and 10 seconds
......@@ -35,6 +35,22 @@
namespace otb
{
/**
* \class S1ThermalNoiseLookupData
* \brief Calculate the Sentinel 1 thermal noise contribution for the given pixel
*
* This class computes the thermal noise using the noise LUTs contained in the product
* metadata. Range noise and azimuth noise are considered. The noise contribution is
* the product of the interpolated LUTs at the pixel index. Only range noise is used
* if the azimuth noise LUT is not available (it is the case for older products).
*
* Reference: MPC-0392 DI-MPC-TN Thermal Denoising of Products Generated by the S-1 IPF
*
* This class is templated over the input image type and the
* coordinate representation type (e.g. float or double ).
*
* \ingroup OTBSARCalibration
*/
template <class T = double>
class S1ThermalNoiseLookupData : public itk::LightObject
{
......@@ -52,23 +68,21 @@ public:
/** RTTI */
itkTypeMacro(S1ThermalNoiseLookupData, itk::LightObject);
/** Set input metadata containing denoising LUTs */
void SetImageKeywordlist(const ImageKeywordlist & kwl);
using IndexValueType = itk::IndexValueType ;
/** Compute noise contribution for a given pixel */
T GetValue(const IndexValueType x, const IndexValueType y);
T GetRangeNoise(const IndexValueType x, const IndexValueType y);
T GetAzimuthNoise(const IndexValueType x, const IndexValueType y);
protected:
S1ThermalNoiseLookupData() : m_FirstLineTime(0.), m_LastLineTime(0.) {m_FirstLineTime = 1.;};
~S1ThermalNoiseLookupData() = default;
private:
/** Structure containing the azimuth noise LUT */
struct Sentinel1AzimuthNoiseStruct
{
int firstAzimuthLine = 0;
......@@ -80,21 +94,35 @@ private:
std::vector<float> vect;
};
/** Compute range thermal noise contribution */
T GetRangeNoise(const IndexValueType x, const IndexValueType y);
/** Compute azimuth thermal noise contribution */
T GetAzimuthNoise(const IndexValueType x, const IndexValueType y);
int GetRangeVectorIndex(int y) const;
int GetAzimuthVectorIndex(int x, int y) const;
int GetPixelIndex(int x, const std::vector<int> & vec) const;
/** First line of the S1 product */
double m_FirstLineTime = 0.;
/** Last line of the product */
double m_LastLineTime = 0.;
/** Duration between two lines */
double m_LineTimeInterval = 0.;
int m_NumOfLines = 0;
int m_RangeCount = 0;
int m_AzimuthCount = 0;
/** Range noise LUT container */
std::vector<Sentinel1CalibrationStruct> m_RangeNoiseVectorList;
/** Azimuth noise LUT container*/
std::vector<Sentinel1AzimuthNoiseStruct> m_AzimuthNoiseVectorList;
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment