-
Notifications
You must be signed in to change notification settings - Fork 9
Starting
Open GRASS GIS and load or create your project location. If you do not know how to configure a project in GRASS, take a look here.
Observation: Make sure that your imported maps are in a projected coordinate reference system (CRS), in which distances are measured in meters, so that areas and distances are calculated in a meaningful way.
** Mudei aqui**
** SERA QUE VALE A PENA FAZER UNS PRINTS E MOSTRAR COMO CONFIGURAR UM PROJETO GRASS? eu acho que sim... Re: ASSIM? Será que compensa organizar essa seção em links diferentes? **
After that, you should import your raster maps into GRASS environment. Have a look at this and this.
<** SERA QUE VALE A PENA FAZER UNS PRINTS E MOSTRAR COMO importar? eu acho que sim... ** daria para mostrar pela linha de comando (sem print, só usando comando aqui mesmo) e tb uns prints de como fazer isso pela interface do grass, só apertando botoes (colocar todos os prints em slides de ppt!)>
To work with your own GIS data, you must create a location with an EPSG that is similar to your data´s. For example, if your rasters are in UTM 23 South projection with a SIRGAS 2000 datum, your GRASS location should be exactly on this projection. Follow the next steps to create a projection and import a raster map, so you can run LSMetrics with your own data.
Click on New Location wizard as follows:
)
Browse the file containing the rasters of interest:
Choose a simple name for your Location (Here we keep as the default newLocation). Don´t use spaces on the name, nor special characters!!!!!!!!!
Now it´s time to select your working EPSG, which is basically the spatial reference system you data have. If you don´t know which one is it, figure it out here.
You also can easily read the right spatial references system from a georeference file.
Just find the file in you computer and GRASS will get the EPSG code from it. Follow the steps:
After that, you can readly import the raster used for select the EPSG to GRASS environment. If you click "No", then we can import you raster easily as follows. See below.
Now you can star your GRASS session 👍
Now that you opened a grass session, see how GRASS-GIS looks like:
Let´s import your raster data using the function r.in.gdal, but clicking:
Where is your raster data? Browse to import:
And finally, click on "Import"
Follow the next session to visualize your imported map(s) in GRASS display with our example data.
To make your life easier, we make available a GRASS db test file with two raster images. Select the file grassdb_test and Start GRASS session as follows
<** acho que aqui vale a pena colocar os dois mapas (plots) e descrever de onde eles vieram... começa que eu completo. Re: Assim??**>
Note that you can display the maps either by coding or by clicking. If you choose clicking, then follow the steps to visualize out both example data:
Choose the São João raster map:
Choose the Rio Claro raster map:
Now see below how the example maps will appear in GRASS display
São João, State of Rio de Janeiro
Rio Claro map, State of São Paulo
Now see the code for loading the already existent example data:
´d.rast map=APA_Sao_Joao_RJ_cut_SIRGAS_UTM23S@PERMANENT´
´d.rast map=SP_RioClaro_use_raster@PERMANENT´
Now, it is time to use the package itself. Use the GRASS terminal (the black screen) to start LSMetrics. First change to LSMetrics directory and run it using python:
# Change to the code directory where you saved the program (with the version of LSMetrics you want to use)
cd "LS_METRICS/_LSMetrics_v1_0_0"
# Run LSMetrics
python LSMetrics_v1_0_0.py
On MS Windows, you may have to change to the partition where the code is located before changing to its directory. E.g.:
# If the code is on the directory "D:/"
D:
cd "D:/LS_METRICS/_LSMetrics_v1_0_0"
Now take a look at the Windows GUI (the GUI may be slightly different on different operational systems, but is expected to run the same way):
If the GUI does not appear completely in your screen, check your screen resolution (at least 900) and your percent of text display (up to 125%) so that the program window entirely appears. (we'll solve that soon!)