On Mon, Nov 8, 2010 at 10:28 AM, <svn_grass@osgeo.org> wrote:
...
grass/branches/releasebranch_6_4/imagery/i.atcorr/6s.cpp
grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp
Log:
i.atcorr: be less verbose, fix when elevation is not given
(merge r44250 from devbr6)
--- grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp 2010-11-08 09:27:08 UTC (rev 44251)
+++ grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp 2010-11-08 09:28:04 UTC (rev 44252)
...
@@ -331,7 +330,8 @@
G_set_f_null_value(&buf[col], 1);
continue;
}
- alt[col] /= 1000.0f; /* converting to km from input which should be in meter */
+ if (ialt_fd >= 0)
+ alt[col] /= 1000.0f; /* converting to km from input which should be in meter */
/\* check if both maps are active and if whether any value has changed \*/
if\(\(ialt\_fd >= 0\) && \(ivis\_fd >= 0\) && \(\(prev\_vis \!= vis\[col\]\) || \(prev\_alt \!= alt\[col\]\)\)\)
If no elevation is available, perhaps better issue a warning/fatal error?
I am not very familiar with this code so I dunno but in general
performing atmospheric
correction without DEM can lead to nonsense. But perhaps my observation is
not applicable in this code chunk.
From what I can read if no file descriptor is found then do not
convert meters to km
If no file descriptor is found it should fall back to a single
altitude value found in the input parameter file, the crux is that the
value is in meters too...
A good modification would be to remove elevation (ialt) value from
parameter file and make it a separate input value to clarify the issue
value Vs raster input file. Likewise for visibility (ivis).
Yann Chemin
www.csu.edu.au
On 09/11/2010, at 4:43, Markus Neteler <neteler@osgeo.org> wrote:
On Mon, Nov 8, 2010 at 10:28 AM, <svn_grass@osgeo.org> wrote:
...
grass/branches/releasebranch_6_4/imagery/i.atcorr/6s.cpp
grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp
Log:
i.atcorr: be less verbose, fix when elevation is not given
(merge r44250 from devbr6)
--- grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp 2010-11-08 09:27:08 UTC (rev 44251)
+++ grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp 2010-11-08 09:28:04 UTC (rev 44252)
...
@@ -331,7 +330,8 @@
G_set_f_null_value(&buf[col], 1);
continue;
}
- alt[col] /= 1000.0f; /* converting to km from input which should be in meter */
+ if (ialt_fd >= 0)
+ alt[col] /= 1000.0f; /* converting to km from input which should be in meter */
/* check if both maps are active and if whether any value has changed */
if((ialt_fd >= 0) && (ivis_fd >= 0) && ((prev_vis != vis[col]) || (prev_alt != alt[col])))
If no elevation is available, perhaps better issue a warning/fatal error?
I am not very familiar with this code so I dunno but in general
performing atmospheric
correction without DEM can lead to nonsense. But perhaps my observation is
not applicable in this code chunk.
>From what I can read if no file descriptor is found then do not
convert meters to km
If no file descriptor is found it should fall back to a single
altitude value found in the input parameter file, the crux is that the
value is in meters too...
A good modification would be to remove elevation (ialt) value from
parameter file and make it a separate input value to clarify the issue
value Vs raster input file. Likewise for visibility (ivis).
when playing with i.atcorr, input raster maps are very small (450x450)
in my case. Without `ialt` i.atcorr runs for few seconds, with this
parameter it runs for ten minutes and still computes - is that normal?
- sorry knowing very few about i.atcorr.
when playing with i.atcorr, input raster maps are very small (450x450)
in my case. Without `ialt` i.atcorr runs for few seconds, with this
parameter it runs for ten minutes and still computes - is that normal?
- sorry knowing very few about i.atcorr.
Hi Martin
I am going to office now
Can you send me your input files and script
Thank you
Yann
Yann Chemin
www.csu.edu.au
On 09/11/2010, at 7:23, Martin Landa <landa.martin@gmail.com> wrote:
2010/11/8 Martin Landa <landa.martin@gmail.com>:
when playing with i.atcorr, input raster maps are very small (450x450)
in my case. Without `ialt` i.atcorr runs for few seconds, with this
parameter it runs for ten minutes and still computes - is that normal?
- sorry knowing very few about i.atcorr.
Apologies, input altitude in param file is in Km (negative) already.
The test in the code is assessing if file descriptor for altitude
raster is positive and not null, confirming that the alt row buffer is
populated, therefore permitting processing from meter to Km
conversion.
if not available, global unique value is taken in the process of
inversion model re-definition.
So this seem justified to use.
On 09/11/2010, Yann Chemin <yann.chemin@gmail.com> wrote:
From what I can read if no file descriptor is found then do not
convert meters to km
If no file descriptor is found it should fall back to a single
altitude value found in the input parameter file, the crux is that the
value is in meters too...
A good modification would be to remove elevation (ialt) value from
parameter file and make it a separate input value to clarify the issue
value Vs raster input file. Likewise for visibility (ivis).
Yann Chemin
www.csu.edu.au
On 09/11/2010, at 4:43, Markus Neteler <neteler@osgeo.org> wrote:
On Mon, Nov 8, 2010 at 10:28 AM, <svn_grass@osgeo.org> wrote:
...
grass/branches/releasebranch_6_4/imagery/i.atcorr/6s.cpp
grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp
Log:
i.atcorr: be less verbose, fix when elevation is not given
(merge r44250 from devbr6)
--- grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp
2010-11-08 09:27:08 UTC (rev 44251)
+++ grass/branches/releasebranch_6_4/imagery/i.atcorr/main.cpp
2010-11-08 09:28:04 UTC (rev 44252)
...
@@ -331,7 +330,8 @@
G_set_f_null_value(&buf[col], 1);
continue;
}
- alt[col] /= 1000.0f; /* converting to km from input which
should be in meter */
+ if (ialt_fd >= 0)
+ alt[col] /= 1000.0f; /* converting to km from input which
should be in meter */
/* check if both maps are active and if whether any value has
changed */
if((ialt_fd >= 0) && (ivis_fd >= 0) && ((prev_vis !=
vis[col]) || (prev_alt != alt[col])))
If no elevation is available, perhaps better issue a warning/fatal error?
I am not very familiar with this code so I dunno but in general
performing atmospheric
correction without DEM can lead to nonsense. But perhaps my observation
is
not applicable in this code chunk.