Lecture 13

IIT Kanpur July 201
20 followers
Mar 1, 2024
[Music]
hello everyone so in our last lecture we
have shown you that how we can Geor
reference different kind of satellite
images with the help of qgi software so
we have give you a demonstration on uh
how we can GE reference a topo sheet
and uh we can GE reference a image with
the help of bual map service so in this
lecture we will show you that how we can
do the uh merging and mosaicing of
different uh satellite images on the qgi
software and then we will uh give you a
uh demonstration on the shape file
generation and uh we will also uh show
you that how you can uh use the
attribute table of different shap files
and you can generate different kind of
information of those shap files so when
you will open your qgi software and you
have to load the uh satellite data uh
which you want to merge or moac so I
have opened here the uh the satellite
data of srtm this is the srtm Dem so I
have opened the five images and I will
will show you that how you can um first
I will uh uh show you that how you can
mosac of two images to moac uh two image
you have to first select that which two
image you want to mosac so here you can
see in your layer panel here five images
has been opened and you can see this uh
this is a uh image which is uh slightly
little bit away from this four image so
to mosac you have to choose two image
which are uh which are nonadjacent
images and to merge uh you have to
choose two adjacent images so first I
will uh show you the uh moosing part for
that you have to choose two image which
are not adjacent to each other so for uh
this
exercise uh I will choose two image so
uh to do the mosing first you have to go
to the raster option because these are
all the uh raster image and all the
algorithm which you will use to uh do
the moing that is in the raster option
you will find this options uh this uh
plugins in the raser options so in the
rter option here you can see there is uh
certain plugins are given here in
miscellenous option you will see that
here uh few more options are given such
as build bu virtual roster roster
information and merge so in uh with the
help of this buil virtual roster plugin
you can moac to different
image when you will open this build
virtual roster uh option then you will
see such type of window will open and
here in the input layer you have to
select the images which you want to
mosac so I suppose I want to mosac uh
two images for example this uh 30° and
78° longitude and uh 28 and 80 uh
28° uh latitude and 80° longitude image
so for this uh I have selected this two
image and here you can see uh you have
there is uh some more information that
you have to uh give the uh uh uh uh for
example the resolution that resolution
you have to select that the average high
or lowest so by default you will see
that this is uh set on the average and
the another option is the virtual roster
so you have to save your file where you
want to save by default if you are not
saving your file a virtual roster file
will uh uh save in the qgs platform only
but if you will set a directory then on
the directory your file will be saved so
uh to save your file you can uh click on
this option and here you will see that
two options you can uh see over here the
save to a temporary file that means this
your temporary file will be generated
and that file will be save in your qjs
platform only but when you will uh close
your qgis and on that time your file
will be you you will lost your file and
if you want to permanently save your fi
save your file so you have to set a
directory for that you have to go to
save to the file option and you can give
to the directory and on that directory
your file will be saved for now I will
uh create a temporary file and you can
uh once you have selected all the
criteria then you can just click on the
run so here you can see your virtual
file has been generated on your layer
panel and here you can see that if
suppose I uh close this file and this
this two file has been
moac now you can see this is your single
file has been generated and on this
single file your two file is attached or
this two file is moac so similarly you
can moac many kind of files whatever uh
based on your interest so you can uh
also moac multiple files so now I will
show you that how you can merge two
images as I told you that to merge you
have to choose
you have to choose uh those images which
are adjacent to each other so uh simil
uh again you have to go to the roster
option and in this ra roster option uh
miscellaneous you can see the merge
option with the help of this merge
plug-in you can merge your images so
here you have to uh uh select the input
layer uh which uh for which you want to
uh merge your images so here I these
four Images are adjacent to each other
so I will merge this four Images so
first you have to select this four
images and then you have here you can
see the uh again you have to save the
file to save the file you can give the
directory for now I will uh save as a
temporary file so and then you have to
click on the Run option so your
algorithm will run and you can
see your virtual file has been generated
so this is this is your merge
image earlier you can see that this was
the four image this four these four are
s uh four different files which are
adjacent to each other but once we have
merged these images so one single file
has been generated and the single file
you can see over here so in uh as I also
told you in one of our earlier lecture
that how you can because this is a DM
digital elevation model of srtm data so
you can uh this is a uh black and white
image you can fill color in this image
and you can also generate the hillshade
to get more uh information from your Dam
so to generate uh the hillshade and give
the color you have to go to the property
so once you uh you will once you are in
property option uh then you can see go
to this single band shudo
color first first you can generate the
hillshade so from the hillshade option
you can uh you choose the hillshade and
here you have to uh give the Jed
value you assign the J factor and then
simply apply so here you can see the
your uh merge hillshade of the four srtm
image which we have um merge and we have
uh generated the hill Shed from the from
that uh merge file
now to assign the color you have to
Simply go to the property and choose the
single band shudo color from the single
band shudo color you have to select the
color Ram whichever color you are uh uh
you will assign that will apply to your
D and you have to just apply so here you
can see color has been assigned and if
you want to generate a hill shed uh
color map app for that you have to first
generate the hill shade and
then you have to give the color on that
hillshade you just uh apply the jet
Factor now make a copy of this
file duplicate the layer
and you just just assign color to this
duplicate
layer single Bend shudo color and
the
color and from the blending color
blending option you choose the multiply
so this will
simply apply Color on the hill shed also
so here you can see your color has been
applied the over the hill shed map so
this this exercise I although I already
explained in one of our earlier lecture
so this was just a kind of revision so
now we will move uh little bit further
and we will show you how we can uh
generate different kind of shape files
on this qgs platform this will help you
during the mapping part in our coming
lecture we will also show you that how
we can map different kind of
geomorphological features with the help
of this uh DM or the digital surface
model
images so we will go to the so we will
show you that how we can generate the
shape files
so to generate the shave file you first
have to go to the layer option and you
there is one option is the create layer
so in this uh create layer option you
will see that new J package layer this
is uh your default uh format of the qgis
only and the another option is the new
shave file layer so you can choose this
new shave file layer so that will
generate your shave file but if you are
choosing this new Geo package layer this
this will also generate a shave file
layer but those shavee file you can only
uh open in the qjs platform only but
this uh if you are generating the shave
file with the help of this uh SS uh SSP
format so that format you can open uh on
the GIS as well as the qgis so we will
uh uh create the shape file with the
help of this SHP format so when you are
opening this uh uh shap file option so
here you can see some information you
have to provide to generate the shap
files so first you have to few points uh
you have to keep in mind that the shap
files are the vector files so Vector
files means uh either it is a Point
cloud or it is a line which are
connected with the points or a polygon
which are connected with the uh lines so
these are all the shave files so uh here
uh to generate a shave file first I will
start with the point so point you can uh
Point shape file you can use during the
uh uh labeling of certain uh places for
example if you want to uh uh label your
map
and you you want to add the uh location
name in that in that case you have to uh
choose the uh Point shap file so uh to
generate the point shape file first you
have to give the name file name and that
you have to save uh uh in a directory to
save a directory you just choose the
directory and you just give the name of
the file so uh I I'm just writing the
point
and you save uh uh the file name and
then from the geometry type you have to
assign that which which kind of uh shape
file you want to generate either it is
point multi-point line or polygon so
first I will start with the point and
then you have to give the other
information for example the reference
system for which coordinate system you
want to uh apply on this uh point shape
file so I will choose the wgs84 because
this is
the uh this is widely used coordinate
reference system so I'm choosing this
one you can uh based on your uh Regional
location or based on your base map you
can choose different kind of coordinate
reference system which whichever suit
whichever is suitable to your uh uh area
or your map so now I will just click on
okay okay and here in the uh layer panel
you can see a new file has been
generated with the name of point so when
you will uh click on the uh uh when you
right click over this point here you can
see another option is is two option has
been added one is open attribute table
and another is toal editing and this
togal editing you can also see over your
uh qgis platform so here you can see one
pen shape uh has been generated over
here and with this pen shape this is
also a togal editing uh option you can
enable this uh Point shape file the
another option is the open attribute
table so your attribute table is the all
the information which has been uh
associated with this uh shavee file that
would be Sav in your attribute table so
in uh in uh coming uh few minutes I will
uh explain you that how you can generate
your uh you can build your uh attribute
table or with the help of attribute
table how you can extract information
regarding your uh respective shape files
so here uh all these uh information
regarding your shavee file will be save
so to uh generate the uh shave file for
the point Cloud you have to just enable
the togle editing mode so you just
simply click on the togal editing option
and this will enable a few uh symbols
and here with this symbols you can
simply add the points so here you can
see one option is ADD Point feature so
with this add Point feature you can
simply Mark the point for example if I
want to add a location on this map uh
suppose this is uh this is a reason
called halani so if I want to uh give a
name on this particular reason so I have
to just click over this uh uh location
and once you are clicking over this
location a new popup window will open
and this will ask you to give the ID so
you can start with the one and this is
random number you can assign any number
these numbers are basically associated
with this uh with this uh Point shavee
file which you have just generated so I
am uh giving one and you can click okay
and here you can see one point has been
marked over here and with the help of
your uh attribute table you can see that
in your attribute table one point has
been generated with the ID one and if
suppose you want to give a name on this
uh uh point so you have to Simply add a
new field here uh you can see that only
ID is present right now but you have to
generate a new field on this attribute
table to give a location name for that
here you can see on this uh attribute
table option certain uh certain features
are given and with this help uh with
this feature you can uh simply select
deselect delete copy
paste of uh your shave files and you can
also generate a or add a new field here
in this with this help of new field you
can add a new field so you have to uh
give the uh name of the field so suppose
I want to just uh add the
location so you have to give the
location and then type which type of
information you want to add on this
field so that you have to choose with
this type so suppose I want to give a
text text type of information on this
location because your location would be
your uh kind of name right then in that
on that case you have to choose the text
suppose you want to uh assign a
numerical number on that case you either
choose the whole number or decimal
number or suppose you want to assign a
certain kind of uh uh information which
is related to date so on that case you
can choose the date option from this uh
type menu so for this uh this case I
will choose the text because I want to
assign the location name and you can
also give the length of the length of
your text so you
can uh Keep It Whatever uh uh length you
want to assign on your name so you can
accordingly choose the length of the
text now click on okay and here you can
see a new field has been added on your
attribute table and you can assign a
name to this attribute table simply you
write a name and that that will add a
name to your location you save your
attribute
table so you simply click on the save
option and now you can see your uh
location name has been added on the
point so s likewise you can add more
point you wherever you want to uh add a
point you can simply click over there
and a popup will open and that that will
ask you to provide some information so
now because we have added a new field
location so now you can see location is
also showing uh on this popup option now
I will I can give it this to ID number
two and location is for example this is
Ram nagar so I will just assign Ram
nagar so here you can see two point has
been added and suppose you want to label
the location on your map so you have to
Simply go to the properties option and
with this property option you can see
that there is one option label just
below the symbology so you can click
over there and now it is by now by
default it is on the No Label option you
have to change this No Label to the
single label and when you click uh on
the symbol label now you have to assign
the you have to choose the location from
the uh drop down menu and once you have
selected the location and simply apply
so now you can see
your your map has been labeled you can
see over here if you can also change the
color from the uh label menu here you
can see the text and you can see the
color option from the color option you
can simply change the
color whichever is suitable lab to your
map so you can assign the
color now you can see RAM nagar and
hanani is labeled on your map so with
the help of this uh Point cloud or the
point shape file option you can generate
the uh Point shape file or you as well
as you can uh uh with this attribute
table you can label your uh location in
case you want to add location on your
map
now we will uh we will go to the uh uh
second exercise of generation the line
shape file to generate the line shape
file you have to go to the uh layer
option and create layer again you have
to generate a new shape file earlier we
have chosen the uh point from the
geometry type now we have to choose the
line first you have to assign the file
name so I will just give the name line
and from the geometry type you have to
choose the line option and uh you have
to also choose the coordinate reference
system which is wgs84
4326 projection code and you just click
on okay so now on the layer panel you
can see that one layer has been added
that is line and with this uh toggle
editing mode you can enable this enable
this uh line and here you can see One op
with this uh add line feature you can
simply draw the line so line would we
use during the uh suppose in in case you
want to uh draw the fults or you want to
uh draw the roads or uh any kind of
linear feature if you want to draw over
your map so you this line uh uh linear
Vector file you have to use this uh
linear Vector file so suppose I want to
just uh add a simple line so to draw the
line you have to just first uh uh once
you enable this tole editing mode so
here you can see one uh symbol which is
used to draw the line has been showing o
over your map panel so you just simply
click with the help of your mouse so
because the uh uh default color is red
so I just uh disable this map Dem now
you can see this with the uh with the
help of your mouse you can simply draw
the line so to stop the uh line or uh
drawing option you have to right click
on your mouse once you right click
so your popup will come and it will ask
you to enter the ID so you can simply
put one and here uh so this uh line has
been draw
and you can see uh this information on
the attribute table so you have to open
the attribute table here you can see one
feature has been added and you can also
add another field for example I want to
just get a length for this line so you
simply add a field name length and then
you choose the type because length is a
numerical number so I will choose the
whole number from the type option and I
will just click on okay so here you can
see length has been added and you can
simply calculate uh the length of this
line with the help help of field
calculator so in uh uh here in uh
attribute table one option is ADD uh uh
field calculator and when you will open
the field calculator here you can see so
two options are given one is create new
field and update existing field so with
this uh help of field calculator you can
create a new field and you can generate
the information for example I want to uh
get the length for my uh my uh shap file
so you can uh directly create your shape
file uh directly create a new field
called length over here or you uh as we
did we first created the uh added the
new field and then we will calculate the
length so for our case we will choose
the update existing field so on this
update existing field from the drop down
menu here you can see two options are
given one is ID or another is length
because our attribute table is uh only
two field which is ID and length so I
want to get the length for my shape file
so I have to choose the length option
and once you have chosen the length
option here you can see the row number
certain uh options are given from the
geometry you will see the uh
area and you will also see the length so
you have to go to the uh here you can
see the length once you you are double
clicking over on the length here at the
bottom left corner you can see the
preview option here your length has been
calculated so once you are clicking on
okay so uh your length will be added on
the on your attribute table so here you
can see this is your
length
so
now you have to save this attribute
table from the uh save icon you minimize
this and similarly you can draw multiple
lines or whatever uh you want to do you
can create any kind of linear features
so that you can do with this linear
shape
file so you have to uh uh save this
shave file whichever you have generated
now we will um we will generate a vector
F or uh now we will generate a polygon
so to generate a polygon again you have
to go to the create layer and then new
shape file and you have to assign the
name
so I have chosen the name and then you
have to choose the geometry type that
would be your polygon and the coordinate
system is wgs84 and and click on
okay so polygon you to create a polygon
here we you can see on the layer panel
we have just added a new layer which is
called a polygon so you just right click
or you can simply go to the tole editing
mode or enable your polygon option once
you enabled your polygon option here you
can see add polygon feature is enabled
and with the help of this add polygon
feature you can simply
draw
polygon so polygons are
basically connected with the lines so to
draw your polygon you use your mouse and
you just simply
click and here you can
see whatever shape you want to generate
that you can generate with the help of
polygon and to once you are done with
your uh mapping or you want to stop your
polygon digitization so you have to just
right click and once you are right
clicking a popup will come and that will
ask you to ID so you just give any
random number so here you can see by
default it is filled with a yellowish
color but you can change your color with
the help
of property option once you are going to
the property here you can see whichever
color you want to assign in your map you
that would be you can do with the help
of property so you can see your color
has been
changed so suppose you you you can
add different polygon with this uh with
the help of this
feature now suppose I have generated
this two polygon and you want to do
certain kind of things with this polygon
feature that you you will see this is a
vector option because all the files
which we have generated either it is
point it is line or polygon these all
files are vector files so whatever
whatever Al algorithm you want to assign
or whatever shapes you want to create
with the help of this Vector file that
you that the plugins you will see on the
VOR option so in this VOR option here
you can see on uh the Geo processing
tool and this Geo processing tool has
been consist with the uh some uh more
options for example if you want to
dissolve this to uh Vector file so you
can do uh this simply clicking with this
uh with the help of this dissolve
function so once you are clicking over
this dissolve function here you can see
you have to assign the input layer so
that would be your
polygon and you can
simply uh dissolve your this two image
now here you can see a new file has been
added name dissolve and you can see this
two file has been dissolved earlier this
these was the two different kind
different file and you can simply select
this two file with the help of this uh
this option select feature by area or
single click once you are uh enabling
this option and you simply click over
your file
so you can see this file has is selected
so how you will know that your file is
selected you can see this uh cross in
each corner of your file these are
basically note points and each note
points are showing in a cross and your
shape is filled with yellow color so
this that means your file is selected so
you can also select different shape file
with the help of this option so so these
these was the two different shave file
once you dissolve this this is a single
shavee file so it is converted to a
single shap
file similarly few more options are
given here you can use this option and
you can see what uh you can generate any
kind of shapes according to your
interest for example there is another
option Union so that what it will do it
will just create a union with uh Union
uh of the this two it will create a
union of this two different shape file
so you can click on the union option and
you can simply click on run and here you
can see this is this is your union of
for this to shave
file so this was for the uh VOR layers
now you can also use this roster option
you can explore this roster option and
here you will also see many uh different
kind of options which you can use to
create your uh Maps or get the more
information for
example suppose I want to get
a uh particular set of uh for example I
want to get a uh small portion of this
map for my use or my uh uh research or
interest so that you can
use uh you can get this uh portion of
map by the clipping of this area so how
you can do that you can
simply you can simply use this shave
file you you have to uh use this roster
option and here you can see from the
extraction you can clip your map so in
extraction there is two option one is uh
click roster y extend that means you
have to when you are enabling this
option you will get you have to assign
the input layer so I want to get file
from my my merged
file so this this is my file from where
I want to get a uh fraction of map and
in clipping extent you can
use three options are given one is
calculate layer calculate from layer
another is use map canvas that will use
your entire map and another is draw on
canvas so you can simply draw that which
fraction of map you want to use for your
interest so I want to just get this much
of map so here you can see your latitude
and longitude has been assigned over
your input image and you can once you
are clicking on run so you can see this
map has been generated so if I just
disable this
map so now you can see this map has been
generated by the clipping method so this
is also a DM but this DM is a small
fraction of the map which we have
merged and the another option
was suppose this was our
map and you want to get
a uh
uh you want to get a uh fraction from
this map so that you you can use uh that
you can get from the shap file so for
example I have to just create a polygon
so to create a polygon you have to
Simply go to the polygon option and
enable the polygon and you draw
whichever fraction you want to get so
once I draw you just give a random
number and click and you select this
polygon once you selected and now you go
to the roster option and extraction and
the first we extracted the map with the
help of clip roster y extent now we will
show you that how you can clip your map
with the help of mask layer that is that
is your vector layer so once you open
open this you have to choose
your input layer and now polygon so you
can see here I have drawn several
polygons so I want to just get a
fraction for this my selected layer so
you have to enable this selected feature
only and you have to just assign the no
data value zero and you click on the run
here you can see your map has been
generated so with the help of this
clipping option you can get a particular
set of map from your regon of
Interest so we will stop here and in Le
next lecture we will show you how we can
generate the anac with the help of CET
images thank
[Music]
you
[Music]
[Music]
[Music]
