SWAT-CUP inconsistency problem and parameter issues with nitrate calibration

329 views
Skip to first unread message

jacqueline

unread,
Sep 6, 2013, 5:56:29 PM9/6/13
to arc...@googlegroups.com
Hi all,

I believe some of you are very familiar with SWAT-CUP here, I will really appreciate it if some one could help me solve some problems I have with CUP calibration results. 

I use CUP for my nitrate calibration, the parameters I want CUP to calibrate are 1:V__NPERCO.bsn   2:V__PHOSKD.bsn   3:V__RSDCO.bsn   4:V__SHALLST_N.gw   5:V__SOL_NO3(..).chm   6:V__SOL_ORGN(..). I let CUP do 50 runs and then used the best parameter set from that in SWAT, just to see if I could get the same results, and it turned out that I couldn't. I figure the files (output files and input file) in CUP project folder probably belong to its last run (in my case, the 50th), so I extracted the parameter set generated by the 50th run and input them in SWAT to check the result, and again, CUP output is inconsistent with the output of SWAT 'default' folder. But when I compare their input files, I am very sure parameter values are the same between SWAT and CUP--I manually changed NPERCO, PHOSKD and PSDCO in basin.bsn in SWAT folder to the same values as in CUP basin.bsn, and use Manual Calibration Helper to replace SHALLST_N, SOL_NO3, and SOL_ORGN values. I've tried for a couple of times, and this SWAT-CUP inconsistency issue always exist. Has anyone encountered the same problem before? 

Another problem I have is when I use CUP simulation result to calculate NS efficiency and R2, my numbers are different from what are given by CUP. The equation I used is NSE = 1 - ( sum( (obs - sim)^2 ) / sum( (obs - mean(obs))^2 ). 

My last question is not related to CUP. After I edited BIOMIX value in .mgt file, sometimes the entire line in the same file containing information of fertilizer application rate (frt_id, frt_kg, etc) that I entered before is erased automatically. This doesn't happen to all the hrus, but only to some of them, which makes it even more confusing. At first I thought maybe these two parameters are designed not to be compatible, but that's certainly not the case in some hrus. Will someone answer this question for mep please?

Looking forward to your reply :) With regards,

Jackie

Seyoum Gebremariam

unread,
Sep 9, 2013, 1:42:01 PM9/9/13
to jacqueline, arc...@googlegroups.com
Jackie:
 
I am using SWAT-CUP and yes I have encountered some of the problems you mentioned.
 
First check that you have the most recent swat-cup downloaded and installed.
 
Secondly, note that the last swat run in swat-cup is not the run that generated your best simulation. To re-run your best simulations outside swat-cup, copy your best parameters to model.in file in the cup project folder. Then open windows command prompt, change directory to where you have your cup project, and run "swat_edit" (without ""), this will write your best parameters to your swat input files. Then when swat editor finishes writing your parameters, run "swat" command and now swat is running with your best parameters and the output generated will be exactly the one that was used to generate NSE values in swat-cup summary results.
 
For the second question you can use this excel formula to calculate nse:
 
1-sumproduct((obs1:obsn-sim1:simn)^2)/sumproduct((obs1:obsn-average(obs1:obsn))^2) which is the same as yours. The reason you are getting nse values  different from that calculated by cup is perhaps your are not using best simulation results to calculate your nse.
 
Best wishes
Seyoum 


--
You received this message because you are subscribed to the Google Groups "ArcSWAT" group.
To unsubscribe from this group and stop receiving emails from it, send an email to arcswat+u...@googlegroups.com.
To post to this group, send email to arc...@googlegroups.com.
Visit this group at http://groups.google.com/group/arcswat.
For more options, visit https://groups.google.com/groups/opt_out.

jacqueline

unread,
Sep 9, 2013, 2:35:10 PM9/9/13
to arc...@googlegroups.com, jacqueline
Hi Seyoum,

Thanks for your reply. I will edit SWAT parameters as you showed me, hopefully it will work. I noticed the last run in CUP is not the best simulation, I just used the parameters from CUP last run in SWAT to test their consistency, but the outputs are different when I compare CUP and SWAT. Someone suggested it might be because SWAT doesn't have SUFI algorithm. Although I found this explanation a little confusing, I will try Parasol algorithm in CUP the next step. I calculated nse of CUP's last run by directly plugging in CUP output values , yet my nse is different. I will try a few more times. Thanks again for your help :)

Best,
Jackie

Seyoum Gebremariam

unread,
Sep 9, 2013, 3:19:02 PM9/9/13
to jacqueline, arc...@googlegroups.com
Jackie:
 
Make sure that first your best parameters calculated by swat-cup are written to swat files and you run swat afterwards from command prompt window if you want to test swat-cup's consistency. The best_par file is located in swat-cups output folder for your save iteration along with best_sim file. To compare first you have to run swat with best parameters. It works if you do it the way I told you earlier.
 
Good luck
Seyoum 

jacqueline

unread,
Sep 9, 2013, 3:35:18 PM9/9/13
to arc...@googlegroups.com, jacqueline
Thanks!
Reply all
Reply to author
Forward
0 new messages