refactor(probe): removed old cout debug statements

This commit is contained in:
2025-04-30 07:35:27 -04:00
parent ff1df81e2b
commit 90083113b5

View File

@@ -58,25 +58,23 @@ void glVisView(mfem::GridFunction& u, mfem::Mesh& mesh,
const std::string& windowTitle, const std::string& keyset) {
Config& config = Config::getInstance();
quill::Logger* logger = LogManager::getInstance().getLogger("log");
std::string usedKeyset;
if (config.get<bool>("Probe:GLVis:Visualization", true)) {
std::string usedKeyset;
LOG_INFO(logger, "Visualizing solution using GLVis...");
LOG_INFO(logger, "Window title: {}", windowTitle);
if (keyset == "") {
if (keyset.empty()) {
usedKeyset = config.get<std::string>("Probe:GLVis:DefaultKeyset", "");
} else {
usedKeyset = keyset;
}
LOG_INFO(logger, "Keyset: {}", usedKeyset);
std::string vishost = config.get<std::string>("Probe:GLVis:Host", "localhost");
int visport = config.get<int>("Probe:GLVis:Port", 19916);
std::cout << "GLVis visualization enabled. Opening GLVis window... " << std::endl;
std::cout << "Using host: " << vishost << " and port: " << visport << std::endl;
const auto vishost = config.get<std::string>("Probe:GLVis:Host", "localhost");
const auto visport = config.get<int>("Probe:GLVis:Port", 19916);
mfem::socketstream sol_sock(vishost.c_str(), visport);
sol_sock.precision(8);
sol_sock << "solution\n" << mesh << u
<< "window_title '" << windowTitle <<
"'\n" << "keys " << usedKeyset << "\n";
sol_sock << "mesh\n" << mesh << u
<< "window_title '" << windowTitle << '\n';
// "'\n" << "keys " << usedKeyset << "\n";
sol_sock << std::flush;
}
}