Calibration Error in SWAT CUP

143 views
Skip to first unread message

tanvir ahamed

unread,
Jan 27, 2026, 9:02:29 PMJan 27
to SWAT-CUP
Dear SWAT-CUP Community,

I have been encountering the following error for the past couple of weeks while calibrating my SWAT-CUP model using streamflow data. Some details of the model are

Number of years simulated: 6
Beginning year of simulation: 2015
number of years to skip output printing/summarization: 2
beginning year of simulation (NOT INCLUDING WARM UP PERIOD): 2017
end year of simulation: 2020

Error Message:

C:\SWAT\Crypto.Spe.SwatCup>SPE_Single_Obj_goal_fn.exe
!ERROR simulation number 2 in variable file 1 is missing or has a problem

C:\SWAT\Crypto.Spe.SwatCup>SPE_Single_Obj_new_pars.exe
simulation no  3  is missing from the single_obj_goal.txt file

C:\SWAT\Crypto.Spe.SwatCup>SPE_Single_Obj_95ppu.exe
Error! simulation 1 has problems


I also attached all the SWAT-CUP tabs for your review. Could anyone please let me know how I can resolve this issue?

Thank you

Tanvir
SPE_swEdit.png
Observed_reach.png
Extract_no_obs_rch.png
File_Cio1.png
Observed_txt.png
Var_file_name.png
Var_file_rch.png
Par_inf.png
SPE_extract_rch.png
File_Cio.png

Ashwin Ghimire

unread,
Mar 30, 2026, 12:23:00 PMMar 30
to SWAT-CUP
Did you fix it? What did you do?

tanvir ahamed

unread,
Mar 30, 2026, 12:35:43 PMMar 30
to swat...@googlegroups.com
Dear Ashwin,

Thanks for your message. Yes, I figured out my problem and fixed it. I just made some corrections on the 'Extract_No_Obs_rch' file and that worked. I can help you if you show the error message and share a screenshot of your model files.

Thank you

Tanvir


NJIT logo
Tanvir Ahamed
Ph.D. Candidate
Department of Chemical and Materials Engineering
ta...@njit.edu • 
901-691-3915
Google ScholarResearchGateORCID| LinkedIn


--
You received this message because you are subscribed to the Google Groups "SWAT-CUP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to swat-cup+u...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/swat-cup/8a29f039-f3f2-46eb-ab99-79b172779211n%40googlegroups.com.

tanvir ahamed

unread,
Mar 30, 2026, 12:36:02 PMMar 30
to SWAT-CUP
Dear Ashwin,

Thanks for your message. Yes, I figured out my problem and fixed it. I just made some corrections on the 'Extract_No_Obs_rch' file and that worked. I can help you if you show the error message and share a screenshot of your model files.

Thank you

Tanvir

Ashwin Ghimire

unread,
Mar 30, 2026, 12:51:45 PMMar 30
to SWAT-CUP
Hi Tanvir,

I'm doing multi variable calibration. And, I have attached the screenshots. Another peculiar thing is that when I run a single simulation, there is no such error like yours (and it gives me the NSE successfully):

C:\SWAT\Crypto.Spe.SwatCup>SPE_Single_Obj_goal_fn.exe
!ERROR simulation number 2 in variable file 1 is missing or has a problem

C:\SWAT\Crypto.Spe.SwatCup>SPE_Single_Obj_new_pars.exe
simulation no  3  is missing from the single_obj_goal.txt file

C:\SWAT\Crypto.Spe.SwatCup>SPE_Single_Obj_95ppu.exe
Error! simulation 1 has problems

But, when i run like 3 simulations, it starts giving me this error.

Thank you for your help.

Ashwin
Observed_rch.txt.png
Observed.txt.png
Var_file_name.txt.png
Par_info.png
Var_file_rch.png
Extract_No_Obs_rch.def.png
File.cio.png
SPE_extract_rch.png
spe_swedit..def.png

Juan Díaz

unread,
Jul 31, 2026, 8:34:21 AMJul 31
to SWAT-CUP
Hi everyone,

I am running a SUFI-2 calibration in SWAT-CUP for monthly discharge, but I am facing an issue where the model crashes or fails right after simulation 1.
 C:\SWAT_ERESMA_8\calibracion_simu5.Sufi2.SwatCup>SUFI2_goal_fn.exe
No se pudo encontrar C:\SWAT_ERESMA_8\calibracion_simu5.Sufi2.SwatCup\SUFI2.OUT\beh_*.*
1     NS=  -0.267154

!ERROR simulation number 2 in variable file 1 is missing or has a problem

C:\SWAT_ERESMA_8\calibracion_simu5.Sufi2.SwatCup>SUFI2_new_pars.exe
Reading goal file
simulation no  3 is missing from the goal.txt file

C:\SWAT_ERESMA_8\calibracion_simu5.Sufi2.SwatCup>SUFI2_95ppu.exe
finished reading observation file
reading FLOW_OUT_1

Error! simulation 1 has problems

C:\SWAT_ERESMA_8\calibracion_simu5.Sufi2.SwatCup>SUFI2_95ppu_beh.exe
Cannot open input file /SUFI2.OUT/no_beh_sims.txt
THIS IS NOT AN ERROR!!
There were no solutions with the
objective function value >=  the behavioral threshold

C:\SWAT_ERESMA_8\calibracion_simu5.Sufi2.SwatCup>rem 95ppu_NO_Obs.exe

Upon troubleshooting, I noticed the following details:

1. When running a single simulation (n=1), SWAT-CUP finishes, but the hydrograph / observed data plots show that SWAT-CUP only reads the very first observed value correctly (e.g., ~4 m3/s). For all remaining time steps (72 months), the observed flow drops to 0.
2. Because all subsequent observed values are being read as 0, the objective function and goodness-of-fit statistics (NSE, R2, PBIAS) are completely unrealistic.
3. Starting from simulation #2, the execution crashes/fails.

What I have checked/tried so far:
- Formatting: Verified column structure, date/number of observations, and header variables in `Observed.txt` / `Observed_Data.txt`. The structure was generated from Excel and dragged down for all rows.
- Tried modifying unobserved file structures as suggested in some forum threads, but I do have full observed streamflow records for the entire period.

    

Could this be related to:
- Hidden characters, line breaks, or tab vs. space delimiters in `Observed.txt`?
- Variable indexing or conflict with Inlets in the TxtInOut folder?
- Decimal separator issues (dot vs. comma)?

Has anyone encountered this specific behavior where SWAT-CUP reads only the first row of observed data and zeroes out the rest? Any guidance or a working template example of `Observed.txt` for discharge would be greatly appreciated!

Thanks in advance for your support.

Best regards,
Juan

Kislaya Kalyan

unread,
Aug 7, 2026, 3:55:02 AM (11 days ago) Aug 7
to SWAT-CUP
Dear Tanvir,

I m also facing the same problem in SWAT-CUP model using streamflow data. i have attached the required file can you please help me with that 

This is the error which i m encountering

D:\callibration\CAL_123.Sufi2.SwatCup>SUFI2_goal_fn.exe
Could Not Find D:\callibration\CAL_123.Sufi2.SwatCup\SUFI2.OUT\beh_*.*
1    NS=  -1.073325

!ERROR simulation number 2 in variable file 1 is missing or has a problem

D:\callibration\CAL_123.Sufi2.SwatCup>SUFI2_new_pars.exe
Reading goal file
simulation no  3  is missing from the goal.txt file
D:\callibration\CAL_123.Sufi2.SwatCup>SUFI2_95ppu.exe

finished reading observation file
reading FLOW_OUT_1
Error! simulation 1 has problems

D:\callibration\CAL_123.Sufi2.SwatCup>SUFI2_95ppu_beh.exe

Cannot open input file /SUFI2.OUT/no_beh_sims.txt
THIS IS NOT AN ERROR!!
There were no solutions with the
objective function value >=  the behavioral threshold

D:\callibration\CAL_123.Sufi2.SwatCup>rem 95ppu_NO_Obs.exe

Thank you
Par_Name.out
observed.txt
file.cio
observed_rch.txt
SUFI2_swEdit.def
SUFI2_extract_rch.def

tanvir ahamed

unread,
Aug 7, 2026, 12:41:07 PM (10 days ago) Aug 7
to swat...@googlegroups.com
Dear Kalyan,

Please send me your SWAT-cup files and I will have a look.

Thank you

Tanvir

Inline image


Tanvir Ahamed
Ph.D. Candidate
Department of Chemical and Materials Engineering

Google Scholar| ResearchGate| ORCID| LinkedIn

Kislaya Kalyan

unread,
Aug 10, 2026, 3:59:16 AM (8 days ago) Aug 10
to SWAT-CUP
Dear Ahamed,

I have attached the screenshot of my project.

Thank you

Screenshot 2026-08-10 132319.png
Screenshot 2026-08-10 132217.png
Screenshot 2026-08-10 132424.png
Screenshot 2026-08-10 132405.png
Screenshot 2026-08-10 131801.png
Screenshot 2026-08-10 132348.png

Wendelyn Baya

unread,
Aug 10, 2026, 4:57:07 AM (8 days ago) Aug 10
to SWAT-CUP

Hello Kislaya, have you tried renaming the FLOW_OUTcms to FLOW_OUT_ 1 in your Observed.txt? Also, in your SUFI2_extract_rch.def try to remove the 7-8th line (i dont know if that will matter since you only need 1 variable, try to delete). Let me know if it works. Thank you.

Kislaya Kalyan

unread,
Aug 10, 2026, 7:14:41 AM (8 days ago) Aug 10
to SWAT-CUP
Dear Baya, 

thank you for the help. After deleting the 7-8th line in SUFI2_extract_rch.def my model run successfully.

Thank you
Reply all
Reply to author
Forward
0 new messages