svalinn / DAGMC

Direct Accelerated Geometry Monte Carlo Toolkit
https://svalinn.github.io/DAGMC
Other
96 stars 63 forks source link

Control GeomQueryTool screen output #856

Closed aprilnovak closed 6 months ago

aprilnovak commented 1 year ago

In Cardinal, we are re-generating an OpenMC DAGMC model on-the-fly based on contours in temperature and density. Each time we re-init DAGMC, the following is printed to the screen

Set overlap thickness = 0
Set numerical precision = 0.001
Initializing the GeomQueryTool...
Using faceting tolerance: 0.0001
Building acceleration data structures...
Implicit Complement assumed to be Vacuum

In a given simulation, we might be re-initing DAGMC 15 times, so this repeated screen output can de-sensitize the user to our other screen output that we do want them to pay attention to. Ideally, this screen output could be optionally hidden.

gonuke commented 1 year ago

We can introduce a convention of this kind of output and a mechanism for users to influence it. We can pass that through to MOAB for the first two lines.

pshriwise commented 1 year ago

Staring at this a little bit more after our call this morning. @gonuke would it be sufficient to add a verbose flag to the GeomQueryTool and GeomTopoTool classes in MOAB? We could then include a method in DAGMC to set the verbosity the classes it depends upon (as well as the verbosity of the DagMC class itself).

makeclean commented 1 year ago

I thought we had one at some point? maybe I'm mis-remembering?

pshriwise commented 1 year ago

Not seeing anything of that nature in the source code 😞 Shame on us...

gonuke commented 1 year ago

Staring at this a little bit more after our call this morning. @gonuke would it be sufficient to add a verbose flag to the GeomQueryTool and GeomTopoTool classes in MOAB? We could then include a method in DAGMC to set the verbosity the classes it depends upon (as well as the verbosity of the DagMC class itself).

I think that would do it, but is still fairly intrusive. We also would have to act on that flag in DAGMC.

pshriwise commented 1 year ago

Agreed, we'd have to act on that flag in DAGMC. And while some changes will be required in MOAB, there's a separate question of how we want to handle verbosity in the DagMC class. Here are the aforementioned lines annotated with which project they come from:

Output Line Class
"Set overlap thickness = 0" MOAB::GeomQueryTool
"Set numerical precision = 0.001" MOAB::GeomQueryTool
"Initializing the GeomQueryTool..." DagMC
"Using faceting tolerance: 0.0001" DagMC
"Building acceleration data structures..." DagMC
"Implicit Complement assumed to be Vacuum" dagmcMetaData

So, as a first step, I think we can decide how we want to handle the output lines coming from DAGMC.

pshriwise commented 1 year ago

Cross-linking related MOAB issue here

https://bitbucket.org/fathomteam/moab/issues/166/control-verbosity-in-geomquerytool

gonuke commented 1 year ago

I think all the pieces are in place for the next release of MOAB. We will still need to add a line in the DagMC constructor to pass along the verbosity.

ahnaf-tahmid-chowdhury commented 6 months ago

Are we ready to proceed with the latest MOAB version now that we have fixed the Implicit Complement Position in DAGMC through PR #935?

gonuke commented 6 months ago

I think it's worth a PR to see how it all works...

ahnaf-tahmid-chowdhury commented 6 months ago

MOAB is set to the latest version 5.5.1 now through #940

gonuke commented 6 months ago

This should now be resolved