HEC-HMS T3: How To Set Up HEC-HMS Model Directly From DEM Using The Latest Version

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hi there welcome back so today i'm going to show you how to calculate the base in average precipitation so in the last tutorial right the part two we already have seen how to download that analysis data so i have this data already downloaded so now i have to even calculate the vase in average precipitation for each of this sub basin or sub watershed right so that is our goal and let me count that i think we have 13 star watershed so i have to prepare that shape files i'll extract that shape file i already mentioned that one right the previous version of heck asymmet doesn't right have that but this little version we can even export that shape file because we created this file from dem so we have to use that this uh shape file to calculate base in average precipitation so how can i export this ship file to our arcmap so that's the option go to gis if you go there you can export layer which one you want you can you can export that sub basin and you can even export other layer as well okay so if i want to export that so i'll export as shift file so you can see that save file i'm selecting the location where i wanna save it okay i have the predefined layers there inside shape files and if i just export it as a sub basin let me just quickly export that i have the previous one so it will be replaced so i'm giving the name sub basin okay sub basin 0 1 and i'm saving that if i finish it it will be there so at the same time if i open my gis that one okay because we are working continuously on gis and we can display everything on gis and we can even change our view to arc uh hey ksms at the same time right so what i'm gonna do right now i'll import that because i need to have that share file for my calculation okay i'll use our script our programming language you were maybe familiar with that one i've written this script maybe more than two and a half years ago so yeah later on i have also a script on python but i'll use that one that i i written in our programming language so here it is if i just zoom out a little bit then yeah so we need to have that base in because we have to even count the name because the names are not right in sequential order because we submerged we merged we merged some of them that's why the names are not in sequential order the highest number of sub basin now is 17 however we have only 13 of sub basin so we have to even remember the name right which one is which then we can create our yeah basin average precipitation based on the same name then we can even connect those otherwise if we just follow one two three four after thirteen so which one [Music] for which one so that will be difficult so that's why i'm just exporting that that i already did and then importing it here if i add that plus sign and then insert hey kcms and then ship file and which one is the one that one i'm selecting sub basin one right so we just exported that one so so that is that if i just turn off this one and these are the sub basin we have if i want to open that attribute table can you see that we have this name subbasin 1 2 and 5 right 6 8 10 11 and see the names are in different order and the basin ids are this right so we need that this sub basic name so we'll create the base in average precipitation and the time series based on that name sub basin one two three and we'll follow the id okay and that that's why we need that so how can i do that we have that option here so the next thing i'm gonna do i'm gonna create a csv file so click on arcmap as before because we need that csv in order to use that in our script i'll use the python script to create time series and i'll use that r script to create base in average specification that's why we need that so which one we have to click conversion right and then excel and then table to excel if i click on that and now i'm going to select that sub in one and then it will be like excel file and i can convert it to csv so it is gonna say there okay arc gis sub basin 1 e2 there if i want to even change it to a different one because we are working on a kcms right now so inside that hey ksms if i put it that sub basin okay sub basin then it will be like xls not a problem it is yeah i think it's already done or it's processing maybe it's working on it okay let me just check it if it is there so it should be inside hey kcms or where it is heck sms there it should be there maybe it's working on it converting to okay yeah converting and done so you can see the message in the lower right corner if i now go to that directory see it's there sub basin so keep in mind i think i don't need that here i have to cut it and i have to go back to that latest version because i'm saving everything there that is the previous version so if i open it see and it will show that sequential order so we what do we have here see the field id is 0 to 12 and the basic name is this one this one and this one so we have to even save this as csv file then we can okay by the same name i'm going to use the same name and csv comma delimited and then save it so i have the csv file because when i'll use that in my script or python script so i'll use that csv so the csv yeah it's looking like that way okay so i'm closing that one and now if i go back to my heck sms model so now i have the sub basin i have the watershed the same watershed right the sub basin i extracted this one so i'll use this one so let me quickly open my r script and at the same time what i'm gonna do here i'm copying that see i have the analysis data that i already downloaded from the 27th of august 2017 to 10th of september 2017. i'm gonna extract that okay so extract all and then it will be extracted here because i made the zip file and then i'm just transferring from one computer to another one that's why it is this so we'll direct to that one so let me yeah i think i also have that scripts so i have to even okay copy those script as well after doing that one let me go to that script as well okay so it's done we have that so i have this value c and these are we already have idea about this one right already i already plotted that one pre today in the previous tutorial so let me just uh copy the script i have in my heck sms so these are the script i'm gonna use uh that one is the python script and i have even our script i'm gonna copy and then i'll put it there okay so there i'll put it there and here it is okay so i have to create i have the r so i have to create a new project if i open or if it is already there so it will show you the logo right the studio the r studio if you click on that or studio because you can find the right how to install rstudio it is not that difficult so what i'm gonna do i'm gonna even create because it is opening the previous one it's asking for installation now i'm gonna create new okay go to file and then new project and new directory then it will be easy for us to a new directory you can select that and new project and select that new directory because we are doing for the first time and here it is okay inside our heck sms not heck sms let us take a hike sms and here i'm detecting that and i'm specifying that basin average okay basin basin everest facing average precept and that is the r so if i create the project it will create another directory there and it's there okay so what i have to do now i have to copy that script inside that basin average r because that is the project and i'm pasting it inside that one if i open so it will be directed to that one so i'm opening this one okay so now i have the script so these are the default uh yeah library that you have to install it's pretty simple if you just install that way so now it's asking to install i'm gonna install that one if there are some library that are missing so it's gonna install okay yeah it's installing and because i maybe updated that or version of this that's why it is asking to even update that so once it's done let me just quickly explain that and let me try to change the directory where i have that file okay let me just copy that going back where i have this okay here here i have all of this net cdf files okay and okay when it's done because it's taking a while not a problem it can take a time because it is downloading and installing is of these packages these are pretty important because we need to even see the rest of this restaurant will be used to read those net cdf file and there will be gdal right rgdl that will be used to even project for projection system we can use gdal or rgdl and we also have other libraries raster vs means is the visualization if you want to plot raster we can do that and we need to have even hdf five or that will read even that near serial file and because we are processing basin average that's why we need different module there and when we are done with installation so what i'm gonna do here i'm gonna while it is installing i'm gonna explain that so these are the necessary libraries i'm just importing so that is the command in python we use import but in r we use library and then the name of the module and here what i have to do i have to set the directory where i have that files okay so here i have that net serial files i'm just changing the backslash to the forward slash so that there won't be any problem and that's that okay so here it is and now i have to specify where i wanna right store that precipitation base in average specification so i'm gonna select the same directory latest version here however i'll create one new directory there i'm just going back and here i'm gonna create one folder by this name because the name is there so inside that folder i'll have that time not time series the base in average precipitation and then we'll calculate the time series from there so file list so from there it will list all these files i'm specifying this directory where i have that files it's pretty simple and straightforward and now what it will do it will just loop through each of these directories and it will just read the bayes name because the base name you can see if you focus on that file name it is nothing but a big name right so it will exclude that part after that a so that's why from starting to a the index number is 19 so it will start from 2 2 0 7 and it will keep up to the time okay we have the year month and day then we need the time as well so that's why i'm just giving the name index base name and then i'm passing that as ncf name my nc file name so 19 to 31 it will give us that file name of the csv file uh with like uh year month day and the hour right in 24 hours 0 to 23 and then what i'm gonna do right now so when it's done i'm just creating their uh date and time and then i'm reading that file using that raster command but in python if i import net cd4 then we need this data set but here we can use raster and then if you pass the file name and if you pass the fes apc we know that right these are the variable then we selected this one while downloading the file and then i'm printing the file name and then just what i'm doing i'm just using i'm using that brick command to make it like a brick it is kind of it is called stacking okay i'm just because we have different layer so i'm just stacking and i'm just uh putting this as a brick if you just pile a brick so that is the thing because it is a net cdf file multi-dimensional file so that is the command and out of that one i'm extracting that and here i'm reading the shape file that is the command read ogr so that is the command to read shift file and i'm passing where i have the shape file let me find that way where i have the shape file i have to specify the location of the shape file based on which it will create that so inside that hey ksms right and say files and the name of the ship file will be base in one okay this one so how can we extract to go to properties and then security and here copy the enter file name with its uh link okay it's it complete a link so there it will be like this so i'm gonna change the slash from back to forward that way and it will be pretty convenient to follow not right now and there won't be any problem i hope so and see so okay what is that ctrl g okay so it will be like this way okay so we are done with even all these directories everything so it will loop through that nc file and it will read that a pcp it is in millimeter and then it is it will stack everything and then see this is the command it will extract this way i'm giving the function mean right and it will do the job for us so that is the base in average i'm passing that share file see we are passing the strip file because that is the command that is the function extract so if you pass that precipitation i'm reading that after it's taking that s dot press if and i'm passing that shape file it will read and it will give us that precipitation right so here i have to specify the id so i have up to 13 so it will be 11 and then 12 and then 13 and i'm going to replace the name so following the same order that is the thing that's why i extracted this one okay because because of this one i extracted the name i have to follow the sequence so i have to go back and then open that sub basin only because of this one i extracted that one okay so let me just uh put it there side by side and okay where it is so these are the thing we have to do right that is that the first one okay the number one will be sub basin one and then we will have number two that will okay let me just put it that way side by side then it's easy to can understand okay so that is the thing you can even follow what i'm gonna do here the first one is that second one i'm okay i'm just copying okay and there that that will be okay control z i'm just uh giving the name two sub basin two and the next one is what the next one is five sub basin five and then we have six okay then we have sub basin number six then it will be in a sequential order and it will be easy to follow and then six to sub basin number eight okay number eight and then it will be ten [Music] and then it will be eleven because i didn't change the name i'm working on different computer that's why it's after 10 it will be 11 and then it will be 12 it will be 12 and then it will be 14 and then it will be 16 it will be 16 14 16 and then we need 17 4 and 3 okay i'm copying this three we need three more watershed and i'm pasting it there so after 16 the next one will be 17 and then it has to be four and then the last one is nothing but three okay so we have the name in sequential order now what we can do we can even run the code it will store based on this sub basin so it is in sequential order and i think it's still installing the packages it's pretty big okay while installing this one what we can do so what we have to do even we have to even download right maybe it's done or still no it's red is there see what you have to do we have to even download the observed stream flow right so we have this usgs station here right so if i wanna download the stream flow for all of these stations right for 15 minute interval because we need that in order to validate our model even though we only use this uh three stations right so i'm gonna even show you how to download for all of this station so what i have to do i have to create the csv file of this list of the station right and the same thing i'm gonna do here if i click there table to excel that will be usgs stations okay and it's gonna save again there no i don't wanna save there i'm gonna save it outside of that okay sms latest version and here it will be usgs and then stations i'm gonna create the list of the stations right for which i'll download because previously what i already demonstrated i put the list inside that code but now i'm gonna show if i pass a list of csv file then what will happen okay so that's why i'm doing this so maybe it's uh see working there and it's done as usual and see oh it's working okay and then i can process that one so i'll process simultaneously this one on that one so usgs stations i have to even create the csv file okay i don't need that i need only this one expanding so see these are the station number okay so we have how many 45 let me just quickly convert it to csv and i'm putting it there by the same name just changing the file type csv comma delimited okay so now it's done i have to upload this file to my linux machine okay i'm gonna run this one in my linux machine and then you'll see what i'm gonna do so here it is and i think you can run the same code in your windows machine not a problem it is easy but since i have access to that one and i can run it pretty quickly so let me go to that directory where i have the script and i'll upload that csv file because i'm accessing remotely this time that's why it is taking a while to log into my system okay i'm accessing from my home to my university so that's why it's taking a while so cd and then what i have to do maybe it's inside okay no it's uh there so what i have to do right now it's there and it should be by my name okay yes and then it yes it should be then again it's working see it's accessing it's taking all time okay and then it will be like okay inside that nwm model okay i'm just waiting a while it's taking to create the list yeah because of that network issue maybe it's taking a while not a problem and that's why it's taking a time to even install all of these packages that i need to process all this thing i'm hoping that maybe it will take more time okay i'm going inside the script and i have the script there to download that 15 minute okay so what i need i need to upload that file inside this one i'm gonna upload that one here okay so uploading that file from here i think i have the csv file there inside latest one and then usgs station csv okay so i'm uploading there so that is the station and let me quickly open see download 15 minute usgs harvey okay i'm gonna use that for harvey because that should specify that location so i'm gonna specify the file name here so previously i was passing the list as this way but now i'm gonna pass that csv file let me copy the name it's there right usgs which one is that i just uploaded it is usgs station name so it should be inside usgs stations that one okay let me check it and this one okay this one sends us into and this one even if i can change the name as it is so i have the same name by this one it is the same file i have so it is same one so i can even use that one as well okay so i'm copy that name i'm copying the name and i'm pasting it and i'm changing that input csv file there and now i have the csv file and i'm specifying the beginning date and the ending date okay so now it will download the file where inside that okay usgs text rv station hillstone or what i'm gonna change it to send justin to okay houston okay houston sen sen jacinto there so it will create one directory and it will create the text file for all of this 45 stations right so in order to do that i have to activate my python environment develop python 3 this time i'm activating this okay so now i'm gonna just run that code right so that will be the download usgs no download rp what is the name of this script let me check that it is download 15 minute okay so that will be download and 15 minute usgs and it will be harvey okay so then it will start downloading the file that we are asking for it is downloading so let me go back and see the name of the file it should be usgs text and harvey so it should be there usgs where is see houston and send just into inside that once it's downloading it's downloading see can you see that yeah it's downloading it's downloading but there will be some files where there will be some missing data so let me just show you we have all of this 45 and you can see if i open that see what it is gonna give us so it's gonna give us this one right there is nothing okay so here it is this is for harvey and it is giving us the same name we don't have this thing see we even can't get anything here maybe because i downloaded this one using the same script from my university and it was working maybe it is because of that server issue okay let me find that usgs rv which one i ran right harvey i run the same one okay if i go back to my that name okay let me just check if the name or file types are same or not that i specified so which one was that send just into usgs send just into right this one it was the previous one i already yeah this one oh i have to provide the name there there there is the okay this one this one should be the name but i have to modify this so not a problem i'm gonna use uh this name because i already modified that one as trying because the script is yeah it's written that way it will see that's why i'm asking it is there it is calling the id from that column okay so i'm saving this script definitely this time it will work there is no doubt about it and i'm gonna delete i'm gonna delete that usgs send just into houston okay where it is that one okay usgs and just into hillstone okay i'm hitting that because i already said that if i hit it it will start downloading the same file and this time it will download definitely the files that's where it's taking time so usgs it should be not csv text file houston sends us into and it is replacing everything see when it will be done then we can see that because it's replacing i'm just waiting for this one let me check if it's done or not still it is downloading and still it is installing okay so it is not a problem we have to maybe wait or we can process by this time this uh stream flow and by this time i think it will be done and then we can use that one as well not a problem therefore i'm just doing this two or three separate processes at the same time because of that issue so i think it's already still downloading then we'll use even another script so we're done we're done and we can see if i see but that's why i have to check before processing our text file we have to check because we don't have see you can see the file size we we don't have a wave so we have different name there so it's creating problem again i'm gonna delete the entire folder because it creates double file the previous one and the newest one right so that's why what i have to do it's deleting and i have to run it again so these are the processing you have to keep in mind and this time i can check i can show that what it is actually doing because all these stations it right doesn't have that precipitation data so we have missing data as well see for example the first one if i open that there is nothing it is empty the data is missing so we have to remove that before running our next script so the next one see it has 201 kilobytes so it has data and for other stations even you can see we have this data 15 minute interval can you see that yeah we have 15 minute interval from 22nd of august to 10th of uh yeah see 11th of september we have that not 11th of september if it's 11th of october i think i don't need that huge data set i mistakenly maybe have written this one so what we need we need this to be 0 9 september okay then it will be easy let me just quickly uh refresh that one it's done let me quickly run it again so that what i'm going to do because i processed it one for del 3d model that's why the data different the date is different i'm deleting that again and if you run it it will take a while okay not a problem so i'm using different scripts so that's why before running that script you have to check and see it's pretty quick and this time maybe we'll have more station that have missing data so where is the it's it's almost done see yeah so we'll delete those stations where we don't have the data and this time see it's from 22nd of august to 0-0 and then the date should be see september 11 and 23rd 45 hour so now we'll run another script but before doing that we'll check which stations are right which station has missing data the stations with one see the size is one these are the missing stations so we're gonna select all of these stations there is with one size one kilobyte so i'm gonna delete otherwise the next chord it won't run because it won't find that condition that i'm gonna give to create that time series so that is the pre-processing we have to keep in mind if you wanna use code we can do that so i selected all of this right missing stations which have missing data so now every stations we have the data if i click any of them let me show yeah we have the data okay so let me run my next script to create the time series these are the text file i just downloaded and now i'll have another script here can you see that so usgs 15 minute text to csv time series maker so that will give us that okay usgs convert 15 minute uh text to time so both way it will work so i'm gonna even uh crea use that one okay if i open this one i have to change the directory where i saved my file so i can remember that i have the file here i just downloaded so i have to give the input directory it is there and i'm gonna save that by the same name but i'm going to change it to csv cs v okay so it will read everything from this file the text file is there right the text files are there and it will create csv files inside this directory since this directory it doesn't exist so it will create a new one and then it will go through all this step i already mentioned that one in my previous videos where i already demonstrated how to download i already demonstrated everything right the condition i specified there so i'm gonna run this script to create so that's why if you have script for every condition then it's pretty easy to even follow right so otherwise it take a lot of time to test that script and it took a lot of time to even yeah do this but now it's life is easy right and at the same time see what it's gonna do oh it is gonna even plot okay okay so let me just kill it because it will take a lot of time i'm gonna use the other script i have it on plot but it will that one convert okay if i use that one it will even that's why i change it to this okay i i can change the these two lines there then it will be easy otherwise it is going to take a lot of time to plot because we don't need to plot okay so usgs convert okay python usgs and then convert okay then it will take less time see it's pretty fast right fast and if i wanna show you that what it is actually doing otherwise it should take like half an hour so we don't have that time right so we have this csv there this csv is basically the time series this time see these are the time series and in cfs and if i plot it you'll see that this is the time series right we can quickly see one of them so we have this time series so from the text file we don't need to even download the text file and import it using data and text legacy everything we don't need that we i just avoided everything the hassle we had that's why whenever i think okay i need to even do the repetitive tasks i write description this is the benefit so see if i even check we need only three right we need only three stations these are the stations and let me check if we have actually the time series we need it is a three five zero zero and four six one zero and six seven zero zero let me check if we because we have many stations we downloaded everything it is another step to show you how to do that so we don't need this one this one so i think it is a seven zero zero zero eight zero seven three zero zero right so far i can remember it is that one okay so that is the station we need this one select that one and we don't have that station we deleted six okay four six one zero so we have another one seven six seven zero zero okay the last one zero seven six seven zero zero so that one okay so we have only valid data for two stations i'm gonna download these stations and i'm putting it inside my directory where i'm saving everything and then we'll add that station in our heck sms model okay so here it is inside that latest version and i'm gonna save that and let me open yeah while saving it i think by this time it's done let me check that if these are there yeah see these are the stations i downloaded so let me check the first one we have right seven seven zero both are same all right that should be three five zero zero i mistakenly downloaded uh this one this should be deleted is not that one what i need i need basically five seven three five zero zero this one right zero eight zero seven three five zero eight okay zero seven three five zero zero so that one i'm gonna download it again and i'm putting it there i think it's done pretty quickly let me open that these two files we have okay three five and six seven so we already checked that we have the data for this one let me check if we have this data for this entire period yeah we have this data not from 22nd of august 2017 we have 25th of august and all the way to maybe let me check that but these data are we have that up to the first of september right but maybe these data are not even uniform maybe we have missing data so these are the 15 minute data okay 15 minute 15 minute up to this date okay not a problem what we can do now we can even import let me check the r still it is installing and downloading everything even i didn't run that so it's just uh installing everything okay okay i don't wanna do that right now it's installing okay if i save that it will just start from the beginning i don't want that okay so what i'm gonna do i'm gonna open these are the steps i'm showing that on record so that you can see what we need to even right need to do all this processing we need so what i'm going to do right now i'm going to add by this time these two observer stations so we have one observation here we don't have we have one but we don't have uh observed data there so we'll have another one there okay so what i have to do i have to go to that component and then times his data manager this time i'll add when i when my precipitation will be done i will add the precipitation we'll have 13 different precipitation time series but this time i'm gonna add discharge gauges okay and new so this will be the name of our stations okay for simplicity i'm gonna right click and then rename and copy the number so that i can't even put it there as the name of our station okay these are the discharge station i'm creating that one it's done and if i create another one i have to go back to the directory and i'm gonna copy the other name so that it it will be the same okay this is how i create and then create so we have two different empty time series okay so here time series and then discharge gauges these are the gauges we have so what do we have to specify we have the data range from 20 second right august 2017 and zero zero up to let me check the data for this one maybe we have that up to 11 right 11 september 11 september 2017 and it is basically 2 23 45 23 45 and then it will create the table but see it is meter cube per second means cms but our data is in cfs so what i have to do you have to select first click on the number and then manual entry cubic meter per second no it's cubic feet per second and the data interval is 15 minute then create this date and now we'll have the table see the date is 15 minute and what i'm gonna do right now i'm gonna even go to that directory open that copy the values and paste it okay so we have the data from august 22 0 0 hour 2 all the way to september 11 and 23 45 i'm i copied okay i'm just copying this one ctrl c and then i'm opening that and i'm pasting it there okay control v so it's there see and you have to check right it's there we have to check 11 45 okay these are the data we can see and then we even we don't need that because we have some missing data but if i click on graph you will see the graph it is showing there okay so in order to be on the safe side what i'm gonna do i'm gonna even uh use the same value for this one or this will be like we have some missing data see if you go next we have some missing data there it is it is not even 11 this one maybe we have some missing data in between that okay in between our different date maybe these are not continuous during this hurricane harvey the measurement was disrupted so that's why they may not be able to even measure right at every 15 minutes so these are the demerit we have to focus on that one okay so we what we have to do we have to even okay run the model less than that time and if i say it is gonna be up to 11 september 12 hour okay 11 september 12 hour it is not going to okay let me select uh to 11 45 let me specify the date 11 september 11 45 then the problem will be solved table is okay the graph is okay so this is otherwise the model won't run okay so now we have this data for this one so what about this one okay this data so it has to be the same fit for second 15 minute manual entry then change the date it is up to uh from 25 5th of august 2017 not from 22nd that's why we have to even specify but here maybe we'll have less time let me check it so this will be first of september 2017 and let me check the data here it is okay and once it's done it's from 25th 45 2015. so the time is 2015 we have to check everything so that it is synchronizing 2015 and first of september okay 2015 i'm gonna copy it all the way to september 1 24 21 30 21 30 specify that first 30 and then it will create the table i already copied right let me check it ctrl c and i'm gonna paste it there click there and ctrl v maybe it is not even covering the entire thing so let me just uh cut it there because we have some missing value in in between our date and time it's covering up to 20 okay 20 august of 1915 so this is how we have to change we are 28th august 1915 so in order to do that 29th august 29 august 15 okay let me check that again 19 15 okay 19 15 on 19 this should be 15 then i think our table will be filled off we can check the graph maybe the table is okay this time is it okay still 25th of august 20 and then maybe it's not let me check it again why okay let me paste it again ctrl v because i'm pasting that still it is not done so while it's not done 28 i guess 1915 the table should be after this okay time 25th august 2015 okay this should be 28 that's why it was not working and this should be 19 15 this time the table should be filled off okay now we have the graph like this okay so this is how we have to kind of specify the problem that we have let me check by this time so what we have we have added right we have added this discharge so where it is located let me zoom in it should be there right where or let me turn off that layer that train layer so that it is pretty easily visible right now okay so that is good okay so then we can even zoom in quickly that should be which one the junction if you click it is junction number eight and go to option and at eight what is the object flow it is that one three five zero zero right we have another observation this is how we can add observation we don't have anything so we have another one this may be seven go to option so the next one is there so when we'll run the model then it will automatically compare the simulation with the observation so this is why we are adding this one okay i'm saving this one let me check if we maybe it's already downloaded see we're done with that one the packages are done so now okay let me run that our script to calculate the vase in average okay so if i run it hopefully it is gonna yeah it's gonna be creating everything yeah it's error in library raster vs we don't have that library why so install install packages install package and if you provide the name the name it is asking okay this one then it will install provide the name it should install okay okay so it's gonna it will be like inside that comma inverted comma okay this one and this one we have to provide it as otherwise not not a problem we'll yeah it's not available maybe it's looking for that one so raster v's okay we don't need that one i'm just turning it off and saving it because we don't need all of this maybe this time it is gonna run or let's see yeah it's working this time see it's creating the vase in avarice and let me show you what it is generating there see it is generating this file see pretty quickly right it's pretty amazing and now it's working inside that fold uh file csv file see these files are basically based on their year right month day and the time see it is in sequential order so i'll use another core to create time series for each of this basin so here it is what is giving it is giving us the values of the precipitation basically these are the sub basin right that's why i created this name and i'll create the time series for this sub basin for each of this sub basin by this name then we'll create the okay so we have to even remember this name the same name one two five six okay to create our gaze it should be one two five six eight ten okay let me create the gauge by this time then we'll add that so these are the sequential order you have to follow to remember okay you have to follow this protocol okay now i'm gonna go to precipitation okay what we can do since we already have the date and time so okay we can even okay we can what we can do we can copy okay right click and copy so that will be guess one means for sub basin one and if you create copy it will copy everything so what we have we need one two right let me check it again we need to do one two five six this will be our name or one two three four one two three four five six or we don't have seven okay so one two three four five six eight let me show you so we have one so now we'll have two okay then we have to get the number two and from guys number two if i create another copy so we have to have grace number three so this will be for sub basin three there so i'm creating the same name or number as we have the number for our sub basin so that will be four and then this is how we have to create five after 13 and then we'll add our precipitation when it's done so these are the process you need to know this is five one two three four five six and then eight right okay so then it will be like six and then copy and paste so it will copy the time you don't need to even create the time again so this is the benefit we have eight and then i can remember that the next one will be 10 so the 10 means it is corresponding to sub basis number 10 so when we'll add that we'll add pretty easily so what is the next number after 10 so 10 is 11 12 14 16 17 okay 11 12 14 we don't don't have 13 and 15 11 12 14 16. so the next one is 11 we already have we have to yeah we have 10 so that one is 11 and then the next one will be 12 next one is 12 this is corresponding to 12 it gets number 12 and the next one will be 14 instead of 13 okay so these are the necessary steps we have to do so we have 14 then we don't have 15 so we have 16 right the number i didn't even change that that's why i'm just doing the same way we have because we merge them together and we don't have that so we have 17. now how many gauges we have see one two three four five six seven eight nine ten eleven twelve thirteen okay so we'll add the precipitation for sub basin number one here and that will be for 10 that will be 4 11 and then i'll add them together how can we do that still since we already have the meteorological model there right so here specify there we can even add now we can add and we can add our gauge number we already have our gauge number right now so it doesn't matter so for sub basis number one we just match that it is one for 10 check the 10 for 11 check it as 11 for 12 it will be 12 this is what i did right for 14 select 14 for 16 it will be corresponding to 16 and for 17 it will be 17 and for 2 it is corresponding to some basic number two and for three where is three there and for four it is also four and four five see this is pretty easy right so that's why you have to follow some algorithm and then experience says that and then eight it is eight okay so now i have linked every basin with every gaze we have okay i'm done with everything i'm saving the project now i need to even add the value of the precipitation because it's empty okay because i copy it still what i have because i copied that thing that's why it copied even the values as well okay so i have to replace these values but if you run the model definitely it will run not a problem it will run what i did if i can run it rv run definitely it will run okay see it's running because i have the values of the precipitation whether it is right or wrong doesn't matter it assume that okay we have the values and see uh the thing i can even show you that at junction number eight right so if i go to result and junction number eight you see we have the comparison between observed and simulated so the simulation is so high compared to observation right compared to observation now that's because our precipitation is same but in reality it is not like that so if i calculate that one that's why i just showed you how to run the model yesterday in the previous tutorial right see let me check that if it's still working okay it's still working and it's generating that because we have more than 400 files see so let me prepare my python script by this time so that we can even work on that so that will be pretty easy let me check if i have spider spider okay i have the spider app i can run that maybe it's not there maybe i okay i remove that do i have that uh anaconda installed uh i don't know maybe okay let me figure it out otherwise i'll run this in my linux machine jupiter jupiter notebook let me check it's not there because i uninstalled that conda so what i have to do not a problem i'll run this in my linux machine to create the time series and then i'll download that again so let me quickly go back and okay here i'll create that time series and then i'm gonna upload the script i have it i'll upload that one and i'll run it you can run the same script wherever you want so upload i have the script there and a loss okay the other one python and the last time series from basin average data so if i open it it's gonna okay wait wait so do i have it there or inside my script it should be there okay let me check it and analyse where is n where is nl does it should be there and okay another last time here is basic average okay there it let me open it and you'll see what we need it is nothing but this one let me check the file it should be up to 11 and then we'll specify that directory let me copy and create one directory there i'll put the precipitation value there uh i have to create one new directory so which one okay that one will create new directory here okay and i'll upload the file inside this one so that's why since it is a linux machine i have to use this command instead of full directory but i have to provide the full name so it will read everything from there and it will create the time series till we need to even read that sub basin that i already passed it should be the same sub base in the csv file i mentioned right so let me open that the csv file i already converted from shift file to csv files so let me go back to that one in two different windows so that we can check it quickly latest one and which one is the sub basin that one okay so this csv file contains that list of the sub basin this one okay in the same sequential order so i have to upload this one there okay this one inside my uh script sub basin maybe let me check if we already have that i tested it okay let me upload that one this way and okay maybe it's there sub basin okay sub basin csv i'm uploading that everything is okay we only have to upload our and it will create the time series by this name input and then it will create the output directory here we have to specify the output directory as well so it will be ti it will be okay heck sms one directory up okay heck okay heck hms time series if it doesn't exist so it will create one as usual and then it will do the job for us not a problem it will do pretty quickly okay so i'm done here i'm just waiting for this process okay we are done with that one so it is it is done up to that one it is not even creating the last file so seven okay seven zero zero in september seven zero zero so the last file we can delete and we can take september six okay so i'm deleting the last file i'm uploading up to september 6 and 23rd so the date is up to september 7. okay we are okay so what i have to do i have to upload the files there okay just i'm going back one directory to base in average precipitation so that i can upload those files and i can run so it will pretty quickly it won't take that much time so fast so it will take only that time to upload okay i'm just control a and it's selected and opening so it will upload everything there this file is 384 file it won't take that much time maybe here it's going to take a while but no it's not going to take that much time is pretty fast because these files are pretty small right in size and then we'll have our time series from that base in average so these are the processing you have to follow specific protocol steps right so that we can even optimize your time see at the same time i'm working on downloading this one and doing that one so i'm running that code and did i save it let me check that okay no i didn't said that so let me save that then everything is same and it's okay so anal thus nl let me okay it's there so if i click it from basic average presentation it will run if everything is okay directory is okay it will quickly see it's reading and reading every file for stop this one then it will create the it's creating the time series okay so it is uh what what is the name of the output file it is heck sms right where's that heck sms it will and heck plus sms time series see it is creating everything there it's already done subways in one so we have these values see it's pretty convenient right so if i plot that you can see we have zero and these are in millimeter if i plot it you will see you'll see that it is pretty good i'm showing only one so that you can understand what it is actually going or giving us okay it is giving us this time series so that is exactly what we have have here right this is the hourly data so therefore the peak is 35 millimeter it's so huge and the daily value is more than 500 millimeter so we are done with this one so what i'm gonna do i'm gonna save this file because i just processed it everything so these are the steps you can do you can just go forward and backward but we can even do the same thing it's taking a while to okay since it is plus let me just rename it because it is oh no it's okay okay submission that's oh that's okay let me download that and it will put everything there in my latest version so it's pretty even quick 13 file we have and we have this data so from this facing average we have that hey ksms time series the first one okay first one so what i have to do i have to even change the time okay the time is okay let me go to component the basin i'm removing that one okay so i'm going one by one so guess one that time from 22nd to that should be six of six of september okay 6th of september and that should be 23. so these are the thing i have to even modify and table and table will be up to this one so now i'll open one by one and copy and paste submission 1 it will be for one okay i'm just copying okay wait wait wait so i'm just copying and i'm testing when i'll be done so i'll run it and then i'll stop this tutorial then in the next time in the next segment or next part i'll even estimate the model parameter i'm pasting it there okay i'm pasting it there so i think it's covering the entire time and let me plot it so it is like that if you want to plot and the second one is 10 i'm following from the beginning third is the same 0 0 6 okay it is same 0 6 and 23 we have up to 23 because we're gonna this time we'll run the model from uh 22nd to 23 because we don't have data because we don't need up to uh september 10th okay so it is for ten the next one is for basin number ten where is ten there is 10 follow this way okay so now i'm going to copy for 10 control c and these are the minimal step you have to do and now it is ctrl v right so everything is in millimeter you can see the plot is as it is the second one is for 11 okay change this i should have changed that previously but i copied that the same one okay not a problem so the second one is 11. keep that in mind i'm gonna close this two i'm not gonna save that so this one is for eleven where is eleven this one is eleven okay this will take a while not that too much time only within few minutes i'm done so these are the stuff i have to do control v i'm done i'm seeing the plot it's time and then it will be 12 and it would be faster if we just selected the accurate time because the data is not completed that's why maybe it's showing that way so now it's 12 okay the next one is 12 and it will open and then i'm just ctrl c and ctrl v so these are the matter i have to do and i can see it's time i'm creating and now we have 14 and then it's 0 6 and then it will be up to 23 and then select the table it is 14. keep that in mind that is 14 and then i'm waiting for opening so ctrl c and 14 is done control v i can see that plot see this is the harvey and now it's 16 changing the time 0 6 and it will be up to 20 3 and that is the table that is 16 okay 16. so here it is see still is taking a while but this new model the method is pretty fast and after all this thing still it is taking a lot of time to even set up this model and then the next thing will be like parameter estimation that will even take a lot of time because we'll estimate our curve number because i need to even use the curve number as loss method that is the most convenient method i will show you how to do that from soil map because we ultimately we need to do that so this is 17 okay 17 and then we'll go back to our lower number 17 because i already added that uh guess to our sub basin so that won't take any time it is only taking time to even fill this off okay so that is done then we have to go to two gauge number two it is six and then that will be 23 the table and keep i'm just closing that one pretty quickly so that you can even remember that what is happening i'm refreshing this closing okay i'm done so now it's two right so two i have only few it's even these are the laborious tasks we have to do see i used even i used different programming right code and after all this thing and i have already demonstrated in my previous videos it is already there how to create basic average using now gis so i already demonstrated that one so i'm not gonna show you the same thing you can watch that video i uploaded that one i think more than one year ago so in details it will show you that okay this is this step to create model builder and it will do the same data for yeah for the same data analdos and then you can understand the two steps that's why i'm selecting i'm calculating this time using my python and matlab and our code so i know our programming i know i have knowledge on python matlab so that's whatever i need i quick i can quickly jump on that and then i can use that code to make make it easy okay so you have to do that if you increase your knowledge on different programming language then it will be easy for you to even move faster so now we are gonna finish that up to four right so here on four let me open gauge number four for sub basin for so this is how i'm following the specific step because i created that one so that i'm just optimizing the time now i'm on five it will be zero six if you know the short card then you don't have to do the menial job okay so this is four five go to this one five i think we have only one or two remaining so i'm copying and i'm pasting it there okay so that is for five we have six and we have eight six and twenty twenty three open six and i think we are almost done then we'll run the model and then we'll finish the video and i'll show the result i'll show the result but this time you'll see there will be some similarity in between observation and the simulation okay but previously we used totally abrupt values that's why it was that huge difference right but in reality it won't be like that but still there there won't be 100 missing in between observation and simulation but that's where calibration comes in we have to calibrate our model so the last one i'm gonna do so right while even see i'd even didn't use any uh impervious layer i use only zero but since it is houston city it is basically most of the area is perfect so when it is pervious there will be 100 runoff there won't be any loss but i'm assuming okay there is no impervious layer but in reality it will be this okay so we have to even correct that one i'll calculate from soil map and learn this information how to uh calculate that curve number or percentage imperviousness i'll show that in the next video hopefully okay so i'm done with everything literally everything and i already have done with see i already added this one the corresponding gauge one for sub basin one that's why i just i i was trying to match the name okay 10 is for 10 11 is for 11. you can check that quickly 14 14 and 8 6 5 everything is missing right now so everything is ready so our first thing is ready but still we even change the model parameter right the method we selected like the parameter is selected for canopy canopy is it's okay and lost method basically we have to even select these values you may have to change these values right still we need to change this one so we'll work on that not a problem we'll estimate that one in the next part and we even have have to change with masking game yeah we have to estimate the mass income values because you have to know the x value we know that is from 0 to 0.5 we have we can use the average value 0.25 but what about the mass income k the time we have to estimate that one okay we'll use that so now i'm keeping that as it is i just added the basic average and the observation data now i'm saving that and i'm gonna run the model again if everything is good it will run yeah it's running hopefully that's why we're lucky yeah see the simulation is done it's so fast that's why people are using this software but if you run the model for i run the model for 25 years and it was a bigger watershed than this one and it was taking like half an hour for 25 years of run okay that's why people are using that hydrologic model to generate rainfall runoff and if i wanna show you the result as before eight it is here right we have observation and it will show you the comparison see so still we have one peak there and the simulation is there and our observation is this way so we have to fix that and then what we have we have another one at 7 right so what is the name of this it is junction 7 so find junction 7 and let's see the comparison that one so here see it is uh missing the peak time but still the observation is so high can you see that yeah it is 120 so we even didn't use any imperviousness right definitely it we have to do that because it is houston city it is houston city you know that right it is very big city so let me quickly change that and then i'll show you this is the thing i have to estimate but it is uh nothing but clark there's a loss method there it will be this one see it is even zero so what i'm gonna do i'm gonna use even at some places it will be 100 or sixty percent seventy percent so i'm gonna do even it is a forty percent okay i'm gonna select forty percent for each of this sub watershed sometime it will be more than that but for the sake of uh running this model um using the same value for everyone 40 percent and let me run it again and let's see if there is any change definitely there will be huge change so i know which one is more sensitive because i already have experience on that see now it's this one it's increasing a little bit previously it was lower than that so if we even change other parameter it will increase right it will increase the values and what about that one result and eight this one this time definitely it is also changing okay so the thing is here we have overestimation there and here we have underestimation right but what about the outlet at the sink that is the that is the accumulation of everything see that is huge so we have two different peaks one is there and another is there right on september at the end of august and it started on like i was 27 or 28 so it is like close to 300 3 000 so 3 000 cfs it's pretty huge like 100 000 cms and flowing to the galveston bay right here it is the galveston bay this is the city and that is the galveston bay and it's flowing so here it's flowing the floor location is here see that is the huge lake so all this water from the city because this city is basically what it is impervious right it's a very big city or within texas and it is renowned city most of the high officials are there and big companies are there and then it is flowing towards right this way and it is flowing to the gulf of mexico at the end right if i okay if i show you that one so that's that we started our gis tutorial and we are just following this one up to the generation of a case in this model and then i'll select one big stream to even instead of hacras model okay and then we'll be done with this one so that's that i think we are so far we are good we are on schedule right schedule and right time everything is working so well that's what i was thinking but i was thinking maybe it will take a lot of time maybe my code won't work but everything is working properly the plan i made it's i'm happy with that one so you can try what i just mentioned if you try hard and if you try to learn new thing definitely when your model will run and then definitely you'll remember me that your feeling will be really good if you set up a model and then if it runs definitely you'll get the amusement if you will enjoy the pleasure of running any model if your code is run if your code runs then that is another uh yeah another pleasure we can feel right it only understand or feels the programmer if you run any code and if it runs so that's that i'm not gonna even extend the video anymore so that is the third part if you haven't watched the previous part you can go back and you can see i already demonstrated how to download and install and i created the uh model heck sms model from the dem this is the latest version and the benefit of latest version is that you don't need to even import the shape file that we did previously in the previous version like 4.3 or 4.4 but this one we don't need that and after finishing this tutorial on haka sms i'll even create another hacker sms tutorial on uh graded model because this is the lumped model i'm using and in the other tutorial series i'll even create the la uh graded model i'll use uh standard hard logic grid and i'll show you how to create the gridded precipitation if your model is graded then you have to create the graded precipitation and i'll also use that time i'll run the model for a long time like for 20 or 30 years or 25 years then i'll even use a different loss method soil mercury accounting method okay and then i'll show you how to estimate those parameters and then i'll even for that sma we need like temperature i'll use a penman mounted precipitation so i'll even calculate how to i'll show you how to calculate that relative humidity because it needs that relative humidity pressure temperature and shorthand radiation along with radiation everything i'll show you i'll i already downloaded these uh variables that's why i was downloading when i was downloading this netstudio file from nlpas i selected everything we have every variables there so our data is already available we have the data so we can even process that one when i'll run that one okay so that's that so i'm going to finish up here thank you very much for watching this video and you can practice and let me know if there is any problem you will get problem only if you try otherwise if you see someone is doing and it is looking like very smooth but if you are gonna do it definitely will face different types of problem so that is the reality you have to understand that so practice this thing these are the hands-on training unless you practice you won't learn anything okay so thank you for watching and stay safe and see you in the next tutorial until then goodbye you
Info
Channel: Md Arifur Rahmahn
Views: 278
Rating: undefined out of 5
Keywords: basin average precipitation, basin average rainfall, how to set up hem-hms model from dem, how to calibrate hec-hms model, how to calculate model parameter
Id: jok-yyyVqyY
Channel Id: undefined
Length: 79min 10sec (4750 seconds)
Published: Wed Sep 08 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.