- Thank you received: 24
Stop TaskManager console message
5 years 2 months ago #1843
by hvwahl
Stop TaskManager console message was created by hvwahl
Hi everyone,
is there any way I can stop the printing of the message
to the console whenever TaskManager() gets called? Unfortunately, changing ngsglobals.msg_level does not help.
Best wishes,
Henry
is there any way I can stop the printing of the message
Code:
task-based parallelization (C++11 threads) using xx threads
Best wishes,
Henry
- Guosheng Fu
- Offline
- Elite Member
Less
More
- Thank you received: 6
5 years 2 months ago #1844
by Guosheng Fu
Replied by Guosheng Fu on topic Stop TaskManager console message
I thought that line is helpful...
But if you build ngsolve from source, you may simply comment out the line
78: std::cout << "task-based parallelization (C++11 threads) using "<< task_manager->GetNumThreads() << " threads" << std::endl;
in taskmanager.cpp in the source code and recompile.
But if you build ngsolve from source, you may simply comment out the line
78: std::cout << "task-based parallelization (C++11 threads) using "<< task_manager->GetNumThreads() << " threads" << std::endl;
in taskmanager.cpp in the source code and recompile.
5 years 2 months ago #1845
by hvwahl
Replied by hvwahl on topic Stop TaskManager console message
Hi Guosheng,
thank you for the hint ! The line you suggested looked slightly different in the sources I have, but from that point I now found a way from the python end:
Because I call the TaskManager only where its needed (twice in every iteration of my time loop), my own output is drowned in the console by this message.
Best wishes,
Henry
thank you for the hint ! The line you suggested looked slightly different in the sources I have, but from that point I now found a way from the python end:
Code:
from pyngcore import SetLoggingLevel, LOG_LEVEL
SetLoggingLevel(LOG_LEVEL.Warn,"TaskManager")
Best wishes,
Henry
5 years 2 months ago #1846
by matthiash
Replied by matthiash on topic Stop TaskManager console message
Hi Henry and Guosheng,
Thank you all for the investigation. I changed the code in NGSolve such that
also sets the logging level in ngcore accordingly, see commit
github.com/NGSolve/ngsolve/commit/431f0c...19258bcaee780a5f51b3
Setting the level to 3 or below mutes the message of the TaskManager.
I also issued a nightly build with this version which is already online.
Best,
Matthias
Thank you all for the investigation. I changed the code in NGSolve such that
Code:
ngsglobals.msg_level = level
github.com/NGSolve/ngsolve/commit/431f0c...19258bcaee780a5f51b3
Setting the level to 3 or below mutes the message of the TaskManager.
I also issued a nightly build with this version which is already online.
Best,
Matthias
The following user(s) said Thank You: hvwahl
Time to create page: 0.107 seconds