<div dir="ltr">
<span style="font-size:small;text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Dear Nikos,</span><div style="font-size:small;text-decoration-style:initial;text-decoration-color:initial">Thanks a lot for the explanation.</div><div style="font-size:small;text-decoration-style:initial;text-decoration-color:initial">Regards,</div><div style="font-size:small;text-decoration-style:initial;text-decoration-color:initial">Gabriel</div>
<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 6, 2018 at 4:55 AM, Nikos Alexandris <span dir="ltr"><<a href="mailto:nik@nikosalexandris.net" target="_blank">nik@nikosalexandris.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">* Gabriel Cotlier <<a href="mailto:gabiklm01@gmail.com" target="_blank">gabiklm01@gmail.com</a>> [2018-07-05 18:28:30 -0300]:<span class=""><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Dear Markus,<br>
Thanks a lot for the explanation. For some reasoner every time I try to run<br>
g.region I can's and I got this pop up dialog box as in the figure below,<br>
and apparently g.region does not run...<br>
How could be possible to solve it?<br>
Thanks a lot again.<br>
Best regards,<br>
Gabriel<br>
</blockquote>
<br></span>
It is friendly, from the Operating System's side, trying to help in<br>
handling GRASS GIS' .region files. Obviously, though, not required in<br>
this case. It looks like you would need to search for how to tell the<br>
Operating System to ignore .region files.<br>
<br>
<br>
Thanks for the summary. In a shorter version:<br>
<br>
r.in.gdal -a input=Fxy # for all images<br>
g.region raster=Fx # only once<br>
i.nightlights.intercalibration ...<br>
<br>
or<br>
<br>
r.in.gdal input=Fxy # for all images<br>
r.region -a map=Fxy # for all images<br>
g.region raster=Fx # only once<br>
i.nightlights.intercalibration ...<br>
<br>
<br>
More detailed<br>
<br>
# import *all* images with<br>
r.in.gdal -a input=Fxy<br>
<br>
(<br>
This is the import command for one image. All related images have to be<br>
imported like that. Easier via a for loop, i.e., under Linux, and within<br>
from the directory where all images reside,<br>
<br>
for RASTER in Fxy*.tif ;do r.in.gdal -a input=$RASTER output=$(basename $RASTER .tif) ;done<br>
<br>
This is a somewhat more elaborated one-line command. This is easily<br>
to be done through the GUI: you can select a "directory" from<br>
inside which to import images.<br>
<br>
I recall also a related post from Helmut, on how to approach this in<br>
Windows, in the command line.<br>
)<br>
<br>
# set the computational region<br>
g.region raster=Fxy<br>
<br>
# inter-calibrate your images<br>
i.nightlights.intercalibration ...<br>
<br>
<br>
What about r.region?<br>
<br>
First, some clarifications:<br>
<br>
- `r.in.gdal` imports a raster/image in to the GRASS GIS data base, by<br>
converting it in a GRASS GIS native raster format. It also sets the<br>
extent and resolution of a raster/image.<br>
<br>
- `r.region` works directly on the images extent. It is a tool to modify<br>
the raster's metadata directly.<br>
<br>
- `g.region` set the computational region for a GRASS GIS Location/Mapset,<br>
which is then what almost all raster modules will consider as the<br>
"active" region to perform computations on.<br>
<br>
<br>
The `r.region -a` would come in play in case you have already imported<br>
the image without the `-a` option for `r.in.gal`, say Fxy. and then you'd want to fix the pixel size<br>
imprecision issue that Markus pointed out.<br>
<br>
That would be:<br>
<br>
r.in.gdal input=Fxy # for all images<br>
r.region -a map=Fxy # for all images<br>
g.region raster=Fxy # only once!<br>
i.nightlights.<wbr>intercalibration # for all related images<br>
<br>
<br>
Since you are re-importing the images, using `r.in.gdal -a`, you don't<br>
need to employ r.region at any step.<br>
<br>
<br>
Finally,<br>
<br>
if the above won't work, then there be something else that causes the<br>
problem.<br>
<br>
Please, do not hesitate to write back about this. We all have our own way<br>
of learning. If whatever is discussed so far, is still not clear enough,<br>
then let us try one more time: I will try to learn/improve how to better<br>
communicate, in written form, these command instructions. And you could try to<br>
go through what is written one more time, and take notes, one-by-one.<br>
<br>
Best, Nikos<br>
</blockquote></div><br></div>