Skip to content

Conversation

@plesskem
Copy link
Contributor

@plesskem plesskem commented Dec 3, 2025

I added to GSTATS an internal flag LCSV_STATS that is only true for LDETAILED_STATS that prints a csv file with timing and communication information per rank. The motivation is to have the raw recorded data to analyse and plot it more easily via e.g. pandas dataframes.
I will maybe later add some more recorded information to the csv file and also make LCSV_STATS an option to be set externally via the namelist but it is supposed to be always true per default for LDETAILED_STATS.

Copy link
Collaborator

@wdeconinck wdeconinck left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! That will be nice.
Just a small change request in real / integer divisions, just to be certain.

! TIMING INFORMATION
ICALLS = NCALLS(JNUM)/2
IF (ICALLS > 1) THEN
ZSTDDEV = 1000._JPRD*SQRT(MAX((TIMESQSUM(JNUM)-TIMESUM(JNUM)**2/ICALLS)/(ICALLS-1),0.0_JPRD))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
ZSTDDEV = 1000._JPRD*SQRT(MAX((TIMESQSUM(JNUM)-TIMESUM(JNUM)**2/ICALLS)/(ICALLS-1),0.0_JPRD))
ZSTDDEV = 1000._JPRD*SQRT(MAX((TIMESQSUM(JNUM)-TIMESUM(JNUM)**2/REAL(ICALLS,JPRD))/REAL(ICALLS-1,JPRD),0.0_JPRD))

@wdeconinck
Copy link
Collaborator

It would be good to create a small test that creates such file.

@wdeconinck wdeconinck force-pushed the feature/csv_output_1.6.1 branch from 9d30246 to ea3e217 Compare December 18, 2025 13:24
- using gstats_setup.intfb.h
- correct dimensions for kprcids
- correct dimensions and type for avearray
- make test work with and without MPI
@wdeconinck wdeconinck force-pushed the feature/csv_output_1.6.1 branch from ea3e217 to 936d8ce Compare December 18, 2025 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants