Indian Forum for Water Adroit

VIC hydrological model- sample data

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
VIC hydrological model- sample data
« on: January 05, 2017, 07:23:52 PM »
Hi everybody
I have downloaded VIC 5.0.0 and I want to work with Stehekin sample data for starting. I created the vic_classic.exe file. what command should I exactly use to read the global parameter file? I know about vic_classic.exe -g global_param.STEHE but I don't know exactly how to use it because the exe file and the global parameter file are in two different folders. I tried moving the exe to the folder that the global parameter file exists but I get this error: "[ERROR] ../shared_all/src/open_file.c:61: errno: No such file or directory: Unable to open File ${VIC_SAMPLE_DATA}/classic/Stehekin/Stehekin_soil.txt".
 

Sat Kumar Tomer

  • *****
  • Thanked: 27 times
  • +116/-0
    • View Profile
    • ambhas
  • Institute : IISc
  • Programming language : R, Python and Matlab
Re: VIC hydrological model- sample data
« Reply #1 on: January 06, 2017, 10:07:47 PM »
HI,

Which operating system you are using?

Please attach the screenshot of command you used.
 
The following users thanked this post: nsalimian

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
Re: VIC hydrological model- sample data
« Reply #2 on: January 07, 2017, 11:52:39 AM »
I'm using ubuntu. the screen shot is attached. tnx
 

thiyaku

  • *
  • Thanked: 7 times
  • +0/-0
    • View Profile
  • Institute : National Institute of Technology Warangal
  • Programming language : Python
Re: VIC hydrological model- sample data
« Reply #3 on: January 09, 2017, 05:41:39 PM »
HI,
I feel no need to move the *.exe file. One can run run vic from anydirectory. Try like this /path/to/vic_classic.exe_folder/vic_classic.exe -g /path/to/global_param_folder/global_param.STEHE
« Last Edit: January 10, 2017, 09:52:55 AM by thiyaku »
 
The following users thanked this post: nsalimian

Diwan

  • *****
  • Thanked: 32 times
  • +12/-0
  • Be a learner or Teacher or helping to learn
    • View Profile
  • Institute : National Institute of Technology Karnataka, Surathkal
  • Programming language : Python, R, Matlab
Re: VIC hydrological model- sample data
« Reply #4 on: January 09, 2017, 10:38:16 PM »
Dear salimian
Pls Check the directory for soil parameter file in the Global parameter
Research Scholar
Dept. of Applied Mechanics & Hydraulics
National Institute of Technology Karnataka
Surathkal Mangalore - 575025
 
The following users thanked this post: nsalimian

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
Re: VIC hydrological model- sample data
« Reply #5 on: January 10, 2017, 02:22:56 PM »
Dear thiyaku, Dear Diwan
I still get this error.At first I had kept the directory of parameter files the same as they were when downloaded. so the "Stehekin_soil.txt" was in the parameters folder. But when I run the vic_classic.exe, the error says "No such file or directory: Unable to open File ${VIC_SAMPLE_DATA}/classic/Stehekin/Stehekin_soil.txt". I copied the soil.txt file and put in this directory, but again I get this error. I even tried changing this part in the global_param_file, but it did not work. If anyone has worked with this sample data, I will be grateful if they could tell me what steps did they do exactly. Thank you
 

Diwan

  • *****
  • Thanked: 32 times
  • +12/-0
  • Be a learner or Teacher or helping to learn
    • View Profile
  • Institute : National Institute of Technology Karnataka, Surathkal
  • Programming language : Python, R, Matlab
Re: VIC hydrological model- sample data
« Reply #6 on: January 10, 2017, 05:35:44 PM »
Pls attach the command and global parameter file you used
Research Scholar
Dept. of Applied Mechanics & Hydraulics
National Institute of Technology Karnataka
Surathkal Mangalore - 575025
 
The following users thanked this post: nsalimian

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
Re: VIC hydrological model- sample data
« Reply #7 on: January 10, 2017, 08:01:09 PM »
Dear Diwan
I solved the problem. I did not enter the correct directory of files in the global parameter file. thank you so much. but now I have a new problem with routing. "niloo@niloo-EP43T-USB3:~/Desktop/route_1.0/src$ make
g77 -O -C -ffixed-line-length-none  -c -o rout.o rout.f
make: g77: Command not found
make: *** [rout.o] Error 127"
 

Diwan

  • *****
  • Thanked: 32 times
  • +12/-0
  • Be a learner or Teacher or helping to learn
    • View Profile
  • Institute : National Institute of Technology Karnataka, Surathkal
  • Programming language : Python, R, Matlab
Re: VIC hydrological model- sample data
« Reply #8 on: January 10, 2017, 10:57:11 PM »
Good to know your problem fixed..
Pls check the required FORTRAN compiler installed in your machine
Research Scholar
Dept. of Applied Mechanics & Hydraulics
National Institute of Technology Karnataka
Surathkal Mangalore - 575025
 

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
Re: VIC hydrological model- sample data
« Reply #9 on: January 11, 2017, 07:28:50 PM »
It seems that the g77 compiler is not installed. I tried "sudo apt-get install g77" but it did not work. and I get "E: Package 'g77' has no installation candidate".
 

Diwan

  • *****
  • Thanked: 32 times
  • +12/-0
  • Be a learner or Teacher or helping to learn
    • View Profile
  • Institute : National Institute of Technology Karnataka, Surathkal
  • Programming language : Python, R, Matlab
Re: VIC hydrological model- sample data
« Reply #10 on: January 12, 2017, 02:35:47 PM »
Try for offline installation... g77 is old compiler which may not be available for repository.. 
Research Scholar
Dept. of Applied Mechanics & Hydraulics
National Institute of Technology Karnataka
Surathkal Mangalore - 575025
 
The following users thanked this post: nsalimian

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
Re: VIC hydrological model- sample data
« Reply #11 on: January 12, 2017, 03:02:48 PM »
I have searched so much for installing g77, but I could not do anything. Could you give me more details about offline installation?
 

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
Re: VIC hydrological model- sample data
« Reply #12 on: January 12, 2017, 07:07:54 PM »
I could finally install g77, but when I try to run "make", I get this error:"/usr/bin/ld: cannot find crt1.o: No such file or directory
/usr/bin/ld: cannot find crti.o: No such file or directory
/usr/bin/ld: cannot find -lgcc_s
collect2: ld returned 1 exit status
make: *** [exe] Error 1"
 

Diwan

  • *****
  • Thanked: 32 times
  • +12/-0
  • Be a learner or Teacher or helping to learn
    • View Profile
  • Institute : National Institute of Technology Karnataka, Surathkal
  • Programming language : Python, R, Matlab
Re: VIC hydrological model- sample data
« Reply #13 on: January 13, 2017, 06:45:51 AM »
Find those location and make a link to it.  Usually the location will be usr/lib/gcc .. If you are not able to link then copy the location to flag in make file provided with model source code .. hope this will work
Research Scholar
Dept. of Applied Mechanics & Hydraulics
National Institute of Technology Karnataka
Surathkal Mangalore - 575025
 

nsalimian

  • ***
  • +0/-0
    • View Profile
  • Institute : Department of civil engineering- Isfahan University of Technology
  • Programming language : matlab
Re: VIC hydrological model- sample data
« Reply #14 on: January 14, 2017, 06:56:35 PM »
Dear Diwan
I tried making the link to those files but it didn't work. I tried this command:

LIBRARY_PATH=/usr/libx32:$LIBRARY_PATH
export LIBRARY_PATH

It seems that the problem with crt1.o and crti.o is solved but it says:" /usr/bin/ld: skipping incompatible /usr/libx32/libm.so when searching for -lm
/usr/bin/ld: skipping incompatible /usr/libx32/libm.a when searching for -lm
/usr/bin/ld: cannot find -lgcc_s
/usr/bin/ld: skipping incompatible /usr/libx32/libc.so when searching for -lc
/usr/bin/ld: skipping incompatible /usr/libx32/libc.a when searching for -lc
collect2: ld returned 1 exit status
make: *** [exe] Error 1"