Ocean Modeling Discussion

ROMS/TOMS

Search for:
It is currently Thu Sep 19, 2019 9:18 pm




Post new topic Reply to topic  [ 7 posts ] 

All times are UTC

Author Message
PostPosted: Fri Jul 05, 2019 6:41 pm 
Offline

Joined: Tue Sep 19, 2017 2:14 pm
Posts: 12
Location: Brown University
Hello!

I have a working version which uses external forcing files (wind, BCs, rivers, ...)

On top of that I wanted to simulate non reactive passive tracers.
So I added variable 'dye_01' to
initial conditions netcdf file, with the same dimensions as that of temperature.

and in the cpp file (.h) file I switched on the following:
#define T_PASSIVE
#define ANA_BPFLUX
#define ANA_SPFLUX

In the input text file, I gave NPT == 1. and switched on Aout(inert) == T .
Apart from the above I haven't made any changes.

I compiled using serial mode (to check), got the oceanS, but when I run I got into segmentation fault error.
I am attaching the .out text file as well as the cpp file, any suggestions would be appreciated.

Best,
Aakash


Attachments:
File comment: cpp def file for reference.
tracer_ngbay.h [1.63 KiB]
Downloaded 8 times
File comment: the output text file which shows segmentation fault error.
segmenfaulterror.txt [46.22 KiB]
Downloaded 9 times
Top
 Profile  
Reply with quote  
PostPosted: Fri Jul 05, 2019 7:45 pm 
Offline
User avatar

Joined: Wed Jul 02, 2003 5:29 pm
Posts: 3670
Location: IMS/UAF, USA
If you recompile with USE_DEBUG=on, you should get filenames and linenumbers instead of those annoying UNKNOWNS:
Code:
oceanS             000000000059C85A  Unknown               Unknown  Unknown
oceanS             000000000059BF55  Unknown               Unknown  Unknown
Without line numbers, we're pretty blind!


Top
 Profile  
Reply with quote  
PostPosted: Fri Jul 05, 2019 8:15 pm 
Offline

Joined: Tue Sep 19, 2017 2:14 pm
Posts: 12
Location: Brown University
well...when I switched on the debug mode, it did not compile but gave error. :oops: :oops: :oops:
attaching the error.


Attachments:
compileerror.txt [50.57 KiB]
Downloaded 11 times
Top
 Profile  
Reply with quote  
PostPosted: Fri Jul 05, 2019 9:02 pm 
Offline
User avatar

Joined: Wed Jul 02, 2003 5:29 pm
Posts: 3670
Location: IMS/UAF, USA
Did you change anything in your build except USE_DEBUG? I assume you cleaned out the old build first. Anyway, it's a link error, not a compile error. The netCDF library wants to link to the curl library. Sometimes, "nc-config --flibs" will want to bring in the curl library. You can add it explicitly to the link statement, but you might have to track it down first. Add to LDFLAGS with
Code:
LDFLAGS += -L/location_of_libcurl -lcurl

LDFLAGS gets set in your Compilers/Sys_comp.mk file.


Top
 Profile  
Reply with quote  
PostPosted: Sat Jul 06, 2019 10:41 pm 
Offline

Joined: Tue Sep 19, 2017 2:14 pm
Posts: 12
Location: Brown University
I added the code

Code:
 LDFLAGS += -L/location_of_libcurl -lcurl


and it got rid of the 'lcurl' error which I was getting while compiling in the debug mode.
Thanks Kate for this suggestion.

Debug mode compilation still was not successful due to some other error.
Anyways I went ahead and compiled with MPI == on and ran the model to see if it runs,
and it ran and I am getting some tracer flow.

So now I have a working tracer model, but the debug mode shows some error which is not affecting my run. Is that normal?

Best,
Aakash


Top
 Profile  
Reply with quote  
PostPosted: Sun Jul 07, 2019 6:57 am 
Offline
User avatar

Joined: Wed Jul 02, 2003 5:29 pm
Posts: 3670
Location: IMS/UAF, USA
It is possible for problems to show up in debug mode that are not fatal when optimized. I still like to get to the bottom of all such issues, if I can.


Top
 Profile  
Reply with quote  
PostPosted: Mon Jul 08, 2019 12:59 am 
Offline

Joined: Tue Sep 19, 2017 2:14 pm
Posts: 12
Location: Brown University
okay, thanks!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group