<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sat, Nov 7, 2015 at 4:09 PM, Barry Smith <span dir="ltr"><<a href="mailto:bsmith@mcs.anl.gov" target="_blank">bsmith@mcs.anl.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
> On Nov 7, 2015, at 2:52 PM, Matthew Knepley <<a href="mailto:knepley@gmail.com">knepley@gmail.com</a>> wrote:<br>
><br>
> On Sat, Nov 7, 2015 at 2:47 PM, Barry Smith <<a href="mailto:bsmith@mcs.anl.gov">bsmith@mcs.anl.gov</a>> wrote:<br>
><br>
> > On Nov 7, 2015, at 1:47 PM, Matthew Knepley <<a href="mailto:knepley@gmail.com">knepley@gmail.com</a>> wrote:<br>
> ><br>
> > On Sat, Nov 7, 2015 at 12:52 PM, Barry Smith <<a href="mailto:bsmith@mcs.anl.gov">bsmith@mcs.anl.gov</a>> wrote:<br>
> ><br>
> > I have no idea what you mean by "scalar data", please expand<br>
> ><br>
> > Lets just make it very specific. I want log_summary to also report something like<br>
> ><br>
> > "L2 error": {0.000134256}<br>
><br>
> Do you mean -log_summary which is just one very specific output of logging data or do you mean tools like PetscLogView_Detailed[] etc.<br>
><br>
> I don't think people should be parsing the output of -log_summary I think they should be writing there own viewers that dump the information in the way they want it (an example of this is PetscLogView_Detailed)<br>
><br>
> I mean adding it to the Python module output (I think that is 'detailed')<br>
<br>
</span> After raking the lawn I think this is a bad idea. The "detailed" Python output is just a viewer for logged time, flops etc. If you want "parsable" Python output from PETSc objects like KSP, TS, Mat etc then you should just write viewers that print python output. If you want problem specific output like actual computed error norms after calling a solver then your example/application should just print that out to a viewer (outputting this stuff should NOT be mixed up in the code with profile outputting). To help this perhaps we need methods like PetscViewerASCIIPrintfPython() that simplifies the printing of the python so people don't have to have things like<br>
<br>
PetscViewerASCIISynchronizedPrintf(viewer,"Stages[\"%s\"][\"%s\"][%d] = {\"count\" : %D, \"time\" : %g, \"numMessages\" : %g, \"messageLength\" : %g, \"numReductions\" : %g, \"flops\" : %g}\n",<br>
<br>
Is that what you mean?<br>
<br>
Perhaps you mean some way of outputting information that is "delayed" until the program ends and then it is printed right next to the -log_view stuff? That sounds like a possible thing to add as well. Perhaps start with an example that outputs some Python information like you want and then we can think about how to do it with viewers and python formatted viewers.</blockquote><div><br></div><div>Yes, that would be fine.</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="HOEnZb"><font color="#888888"><br>
<br>
Barry<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
><br>
> Matt<br>
><br>
><br>
> Barry<br>
><br>
> ><br>
> > Matt<br>
> ><br>
> > > On Nov 7, 2015, at 12:11 PM, Matthew Knepley <<a href="mailto:knepley@gmail.com">knepley@gmail.com</a>> wrote:<br>
> > ><br>
> > > I had many requests from the class to put scalar data into the log_summary. We were generating many summaries using a Python script, which then read them back in as modules and processed the results. We could not automatically get things like the error, which had to be parsed from the output.<br>
> > ><br>
> > > I think allowing users to put scalar data in there would be a good thing. Thoughts?<br>
> > ><br>
> > > Matt<br>
> > ><br>
> > > --<br>
> > > What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
> > > -- Norbert Wiener<br>
> ><br>
> ><br>
> ><br>
> ><br>
> > --<br>
> > What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
> > -- Norbert Wiener<br>
><br>
><br>
><br>
><br>
> --<br>
> What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
> -- Norbert Wiener<br>
<br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div>
</div></div>