-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
unified logging infrastructure #1426
Conversation
New logging infrastructure handles both log messages as well as performance annotations. When caliper is on, we will get caliper output files. When logging is on, we will also get timing info in the log files. The logs are yaml based and support nesting. (An evolution of the VTK-h timing logs) Here are the current Ascent options related to logging and timing info:
With the new logging infrastructure, we are adding log files to the mix. Default case will still be no log file, the The logger allows you to control the level of echo messages independent of what is written to to a log file. The message levels are: We can provide more control with the new system, here is a strawman for options:
Also, for the mpi case - we can limit which tasks actually echo, another strawman:
I suggest that:
and
Of the existing logging macros, To support the log files, we should add new Here are some examples:
With this PR, I don't plan to change the "timings" behavior. VTK-h and Devil ray have their own timing modes, and those will be ported to the new logging infrastructure over time. We also want a simple way to enable logging with sensible defaults, along the lines of:
which would be equivalent to:
|
I like the logging levels you suggested. Thinking ahead to caliper usage, do we want to apply logging levels to caliper? Ex: caliper + logging with info will get you caliper annotations, whereas caliper + logging with debug will also give you caliper loops and iterations. I think I favor the alternative of: caliper is on and you get what we give you, which is everything. But i can be convinced otherwise. |
thanks @nicolemarsaglia! We can explore what type of controls caliper provides to see if we can and gate messages based on level. I do think 99% of the time most users will want all or nothing. We as developers may want to dial it in. |
I am at a good place with initial support for the new logging. The new macros are not wired up in Ascent yet, but we are creating logs and the macros are ready to go. I think we should merge this before we do more refactoring. Please checkout what I have and let me know if you have comments. Thanks! |
For large scale runs, we should support options to control which mpi tasks produce logs:
We can also add these to the |
I also want to add actions that control logging to give users more control than just params in start logging at any time:
flush logs so they can be seen before ascent is closed out:
stop logging and flush current logs:
We will add these actions in a follow on PR, here is an issue to track this: |
ASCENT_LOG_OPEN( file_pattern ) // serial | ||
#else | ||
ASCENT_LOG_OPEN_RANK( file_pattern, par_rank ) // mpi par | ||
#endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
switch?
#if defined(ASCENT_MPI_ENABLED)
ASCENT_LOG_OPEN_RANK( file_pattern, par_rank ) // mpi par
#else
ASCENT_LOG_OPEN( file_pattern ) // serial
#endif
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thank you for finding this, I am working on tests right now
@nicolemarsaglia @emily-howell I think this PR is ready, let me know if you have any more comments or suggestions |
conduit::Node n; | ||
n.load(lfname); | ||
n.print(); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any check for this test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
No description provided.