From 46764d7271d3020aa4050842afc0a82147dca6f0 Mon Sep 17 00:00:00 2001 From: Julien Michel <julien.michel@cnes.fr> Date: Tue, 24 Jan 2017 12:01:10 +0100 Subject: [PATCH] DOC: Add documentation for new deburst code --- .../AppSARCalibration/app/otbSARDeburst.cxx | 12 ++++----- .../SAR/include/otbSarDeburstImageFilter.h | 17 +++++++++++-- .../src/ossim/ossimSarSensorModel.h | 25 ++++++++++++++++++- 3 files changed, 44 insertions(+), 10 deletions(-) diff --git a/Modules/Applications/AppSARCalibration/app/otbSARDeburst.cxx b/Modules/Applications/AppSARCalibration/app/otbSARDeburst.cxx index cf751bc778..376bf55c96 100644 --- a/Modules/Applications/AppSARCalibration/app/otbSARDeburst.cxx +++ b/Modules/Applications/AppSARCalibration/app/otbSARDeburst.cxx @@ -44,14 +44,14 @@ private: void DoInit() ITK_OVERRIDE { SetName("SARDeburst"); - SetDescription("TODO \n"); + SetDescription("This application performs a deburst operation by removing redundant lines. \n"); // Documentation SetDocName("SAR Deburst"); - SetDocLongDescription("TODO \n"); - SetDocLimitations("None"); + SetDocLongDescription("This application performs a deburst operation by removing redundant lines between burst. This operation is useful when dealing with Sentinel1 IW SLC products, where each subswath is composed of several overlapping burst separated by black lines. Lines to remove are computed by SAR sensor model in OSSIM plugins. The output image is smaller in azimuth direction than the input line, because of removed lines. Note that the output sensor model is updated accordingly. This deburst filter is the perfect preprocessing step to orthorectify S1 IW SLC product with OTB without suffering from artifacts caused by bursts separation.\n"); + SetDocLimitations("Only Sentinel1 IW SLC products are supported for now."); SetDocAuthors("OTB-Team"); - SetDocSeeAlso(" "); + SetDocSeeAlso("OrthoRectification"); AddDocTag(Tags::Calibration); AddDocTag(Tags::SAR); @@ -66,9 +66,7 @@ private: } void DoUpdateParameters() ITK_OVERRIDE - { - - } + {} void DoExecute() ITK_OVERRIDE { diff --git a/Modules/Filtering/SAR/include/otbSarDeburstImageFilter.h b/Modules/Filtering/SAR/include/otbSarDeburstImageFilter.h index 23f508c7c5..fb3501114b 100644 --- a/Modules/Filtering/SAR/include/otbSarDeburstImageFilter.h +++ b/Modules/Filtering/SAR/include/otbSarDeburstImageFilter.h @@ -23,8 +23,21 @@ namespace otb { -/** \class SarDeburstImageFilter - * \brief TODO +/** \class SarDeburstImageFilter + * \brief Performs a deburst operation by removing redundant lines + * + * This filter performs a deburst operation by removing redundant + * lines between burst. This operation is useful when dealing with + * Sentinel1 IW SLC products, where each subswath is composed of + * several overlapping burst separated by black lines. Lines to remove + * are computed by SAR sensor model in OSSIM plugins. The output image + * is smaller in azimuth direction than the input line, because of + * removed lines. Note that the output sensor model is updated + * accordingly. This deburst filter is the perfect preprocessing step + * to orthorectify S1 IW SLC product with OTB without suffering from + * artifacts caused by bursts separation. + * + * Note that currently only Sentinel1 IW SLC products are supported. */ template <class TImage> class ITK_EXPORT SarDeburstImageFilter : diff --git a/Modules/ThirdParty/OssimPlugins/src/ossim/ossimSarSensorModel.h b/Modules/ThirdParty/OssimPlugins/src/ossim/ossimSarSensorModel.h index ccaabb6795..2d73f0c73c 100644 --- a/Modules/ThirdParty/OssimPlugins/src/ossim/ossimSarSensorModel.h +++ b/Modules/ThirdParty/OssimPlugins/src/ossim/ossimSarSensorModel.h @@ -244,12 +244,35 @@ public: void optimizeTimeOffsetsFromGcps(); /** - * Produce deburst coordinates and update metadata + * This method will perform a deburst operation, and return the + * a vector of lines range of lines to keep in the image file. + * Note that the deburst operation has no effect if theBurstRecords + * contains a single burst. Otherwise it will merge burst together + * into a single burst, and update GCPs accordingly. + * \return true if the deburst operation succeeded. No changes is + * made to the object if the operation fails. + * \param lines A container for the lines ranges to keep in the + * deburst image. */ bool deburst(std::vector<std::pair<unsigned long,unsigned long> >& lines); + /** + * This is a helper function to convert image line to deburst image + * line. + * \param lines The vector of lines range to keep + * \param imageLine The input image line + * \param deburstLine The output deburst line + * \return True if imageLine is within a preserved range, false otherwise + */ static bool imageLineToDeburstLine(const std::vector<std::pair<unsigned long,unsigned long> >& lines, const unsigned long & imageLine, unsigned long & deburstLine); + /** + * This is a helper function to convert deburst line to input image + * line + * \param lines The vector of lines range to keep + * \param imageLine The input deburst line + * \param deburstLine The output original image line + */ static void deburstLineToImageLine(const std::vector<std::pair<unsigned long,unsigned long> >& lines, const unsigned long & deburstLine, unsigned long & imageLine); /** -- GitLab